← Back to Skills Marketplace
lkmsteven

canslim-analysis

by lkmsteven · GitHub ↗ · v1.0.3 · MIT-0
cross-platform ✓ Security Clean
285
Downloads
0
Stars
0
Active Installs
3
Versions
Install in OpenClaw
/install canslim-analysis
Description
Executes a hybrid quantitative and qualitative CANSLIM analysis on US stocks using a fixed schema and a modular Python pipeline, returning a ranked shortlist.
README (SKILL.md)

\r \r

CANSLIM Hybrid Analyzer\r

\r Analyze US stocks using a three-stage modular pipeline:\r \r

  1. Run a quantitative screen to filter candidates by earnings, leadership, and price/volume behavior.\r
  2. Use OpenClaw AI enrichment to evaluate qualitative catalysts, float tightness, and institutional quality.\r
  3. Generate a final ranked CANSLIM report using a fixed scoring contract.\r \r

When to use\r

\r Use this skill when the user asks to:\r \r

  • Run a comprehensive CANSLIM analysis on US stocks.\r
  • Screen for market leaders combining both quantitative strength and recent catalysts.\r
  • Generate a ranked shortlist with clear met/missed CANSLIM criteria.\r
  • Audit or reproduce the pipeline with deterministic JSON handoffs.\r \r

Required files\r

\r Expected local files (located in Scripts/ directory):\r \r

  • Scripts/quantitative_analyzer.py\r
  • Scripts/final_process.py\r
  • Scripts/pdf_report_generator.py\r
  • Scripts/requirements.txt\r \r Expected generated files (in Scripts/ directory):\r \r
  • Scripts/intermediate_canslim.json\r
  • Scripts/enriched_canslim.json\r
  • Scripts/final_canslim_report.json\r
  • Scripts/canslim_analysis.log\r
  • Scripts/out/canslim_report_{date}.pdf (PDF report with formatted analysis)\r \r

Canonical JSON contract\r

\r The quantitative phase owns Quantitative_Metrics.\r \r The AI phase must preserve every field already present in Quantitative_Metrics and must only fill AI_Qualitative_Checks.\r \r

Intermediate schema\r

\r

{\r
  "Metadata": {\r
    "Schema_Version": "2.1",\r
    "Date_Run": "2026-03-15",\r
    "Market_Direction_M": "Confirmed Uptrend",\r
    "Total_Universe_Scanned": 503,\r
    "Successfully_Evaluated": 487,\r
    "Failed_Fetches": 16,\r
    "Skipped_For_Missing_Fundamentals": 39,\r
    "Stocks_Passed_To_AI": 27\r
  },\r
  "Stocks": [\r
    {\r
      "Ticker": "XYZ",\r
      "Company_Name": "XYZ Corp",\r
      "Quantitative_Metrics": {\r
        "C_Met": true,\r
        "C_Details": "Q EPS Growth: 38.0%",\r
        "Quarterly_EPS_Growth": 0.38,\r
        "EPS_Accelerating": false,\r
        "A_Met": true,\r
        "A_Details": "Annual EPS CAGR: 31.0%",\r
        "Annual_EPS_Growth": 0.31,\r
        "L_Met": true,\r
        "RS_Rating": 92.4,\r
        "S_Quant_Met": true,\r
        "S_Quant_Details": "Today volume >= 1.5x 50-day average, Up-day volume skew positive",\r
        "S_Score": 2,\r
        "Today_Volume_Strong": true,\r
        "Volume_Skew_Positive": true,\r
        "I_Quant_Flag": true,\r
        "I_Quant_Details": "78.0% institutional ownership",\r
        "N_Technical_Met": true,\r
        "N_Technical_Details": "Within 4.0% of 52-week high",\r
        "Near_52_Week_High": true,\r
        "Recent_Breakout": false,\r
        "Pct_From_High": 0.04,\r
        "Current_Price": 145.2,\r
        "Float_Shares": 42000000,\r
        "Institutional_Ownership": 0.78\r
      },\r
      "AI_Qualitative_Checks_Pending": {\r
        "N_New_Catalyst": null,\r
        "N_Catalyst_Details": "",\r
        "S_Float_Tightness": null,\r
        "S_Float_Details": "",\r
        "I_Institutional_Quality": null,\r
        "I_Institutional_Details": ""\r
      }\r
    }\r
  ]\r
}\r
```\r
\r
## Enriched schema\r
The enriched schema must be the same as the intermediate schema, plus AI_Qualitative_Checks.\r
```json\r
\r
{\r
  "Stocks": [\r
    {\r
      "Ticker": "XYZ",\r
      "Company_Name": "XYZ Corp",\r
      "Quantitative_Metrics": { "...": "unchanged and preserved" },\r
      "AI_Qualitative_Checks_Pending": {\r
        "N_New_Catalyst": null,\r
        "N_Catalyst_Details": "",\r
        "S_Float_Tightness": null,\r
        "S_Float_Details": "",\r
        "I_Institutional_Quality": null,\r
        "I_Institutional_Details": ""\r
      },\r
      "AI_Qualitative_Checks": {\r
        "N_New_Catalyst": true,\r
        "N_Catalyst_Details": "New product launch and raised guidance",\r
        "S_Float_Tightness": true,\r
        "S_Float_Details": "Tight float supported by low float and buyback activity",\r
        "I_Institutional_Quality": true,\r
        "I_Institutional_Details": "High-quality institutional sponsorship improving"\r
      }\r
    }\r
  ]\r
}\r
```\r
\r
## Execution rules\r
Follow this checklist exactly:\r
\r
1. Verify files: Confirm Scripts/quantitative_analyzer.py, Scripts/final_process.py, Scripts/pdf_report_generator.py, and Scripts/requirements.txt exist.\r
\r
2. Create environment:\r
```bash\r
python3 -m venv canslim_analysis\r
source canslim_analysis/bin/activate  # Linux/Mac\r
canslim_analysis\Scripts\activate  # Windows\r
```\r
\r
3. Install dependencies:\r
```bash\r
pip install --no-cache-dir -r Scripts/requirements.txt\r
```\r
4. Run quantitative analysis:\r
```bash\r
python Scripts/quantitative_analyzer.py\r
```\r
\r
5. Verify intermediate output: Confirm Scripts/intermediate_canslim.json exists and contains Metadata, Stocks, Quantitative_Metrics, and AI_Qualitative_Checks_Pending.\r
\r
6. Run OpenClaw AI enrichment:\r
- Read Scripts/intermediate_canslim.json.\r
\r
- For each stock, preserve Ticker, Company_Name, and the entire Quantitative_Metrics object unchanged.\r
\r
- Add AI_Qualitative_Checks with values for:\r
\r
   - N_New_Catalyst\r
   - N_Catalyst_Details\r
   - S_Float_Tightness\r
   - S_Float_Details\r
   - I_Institutional_Quality\r
   - I_Institutional_Details\r
\r
7. Write enriched output: Scripts/enriched_canslim.json\r
\r
8. Run final processing:\r
```bash\r
python Scripts/final_process.py\r
```\r
This will automatically generate both the JSON report and the PDF report.\r
\r
9. Display results: Read Scripts/final_canslim_report.json and present the ranked list of stocks, CANSLIM scores, met criteria, missed criteria, price, RS rating, and catalyst note.\r
\r
10. PDF Report: The PDF report is generated in `Scripts/out/canslim_report_{date}.pdf` with professional formatting including:\r
    - Report header with metadata and score distribution\r
    - Individual stock sections with grades and CANSLIM criteria status\r
    - Key metrics tables (RS Rating, EPS growth, institutional ownership)\r
    - Detailed analysis for each criterion (C, A, N, S, L, I, M)\r
\r
11. Delivery: Always attach the CANSLIM report PDF to the user-facing response when the analysis completes successfully.\r
\r
12. Cleanup:\r
```bash\r
deactivate\r
```\r
\r
## Scoring contract\r
Use this exact final scoring model:\r
\r
C: Quantitative_Metrics.C_Met\r
\r
A: Quantitative_Metrics.A_Met\r
\r
L: Quantitative_Metrics.L_Met\r
\r
M: Metadata.Market_Direction_M == "Confirmed Uptrend"\r
\r
N: AI_Qualitative_Checks.N_New_Catalyst == true\r
\r
S: Quantitative_Metrics.S_Quant_Met == true and AI_Qualitative_Checks.S_Float_Tightness == true\r
\r
I: AI_Qualitative_Checks.I_Institutional_Quality == true\r
\r
## Interpretation guidance\r
N_Technical_Met is supporting technical context, not the scored N letter by itself.\r
\r
I_Quant_Flag is reference context, not the scored I letter by itself.\r
\r
A stock can have strong technical N support and still miss final N if OpenClaw cannot verify a fresh catalyst.\r
\r
A stock can have strong volume accumulation and still miss final S if OpenClaw cannot verify tight float or buyback support.\r
\r
## Output format\r
\r
Return the final user-facing answer in this structure:\r
\r
Market Environment:\r
\x3C1-2 sentence assessment of the M criterion>\r
\r
Top CANSLIM Candidates:\r
\r
| Rank | Ticker | Company | CANSLIM Score | Met Criteria | Missed Criteria | Price | RS Rating | AI Catalyst Note |\r
|------|--------|---------|---------------|--------------|-----------------|-------|-----------|------------------|\r
| 1 | XYZ | XYZ Corp | 6/7 | C, A, N, S, L, I | M | $145.20 | 92.4 | New product launch and raised guidance |\r
\r
AI Catalyst Insights:\r
\r
XYZ: Fresh catalyst confirmed; float tightness and institutional sponsorship also verified.\r
\r
Notes & Caveats:\r
Mention missing data, lack of catalyst confirmation, or market-trend caution when relevant.\r
\r
## Constraints\r
Never install dependencies globally.\r
\r
Always use the canslim_analysis virtual environment.\r
\r
Use only files generated by the current skill run.\r
\r
Do not fabricate catalysts, float conclusions, or institutional-quality claims.\r
\r
If no catalyst is found, set N_New_Catalyst to false and explain briefly.\r
\r
If the AI phase cannot verify S or I, set the corresponding value to false instead of leaving it ambiguous.\r
\r
Do not claim results are guaranteed investment advice. Always include disclaimers about risks and the need for further research.\r
\r
## Failure handling\r
\r
If execution fails:\r
\r
State exactly which phase failed: Quantitative, AI Enrichment, or Final Processing.\r
\r
Include the error message when available.\r
\r
Recommend the smallest next step.\r
\r
If the failure is a schema mismatch, state which required field is missing or was overwritten.
Usage Guidance
This package appears internally consistent with its stated purpose. Before running it: (1) Review Scripts/quantitative_analyzer.py if you want to confirm there are no unexpected subprocess invocations or remote endpoints beyond Wikipedia and yfinance; (2) run inside an isolated Python virtual environment as instructed (the skill writes log and output files to the working directory); (3) note that the AI enrichment step is performed by the agent (SKILL.md instructs the agent to read intermediate_canslim.json and add AI_Qualitative_Checks) — if you prefer not to allow the agent to access those files or perform enrichment automatically, perform the enrichment manually or restrict autonomous invocation; (4) no credentials are requested, but the code does make outbound HTTPS requests for public market data (internet access required). If you need higher assurance, run the scripts in a sandbox and inspect the full, untruncated final_process.py for any use of subprocess or external command execution before granting broad agent execution rights.
Capability Analysis
Type: OpenClaw Skill Name: canslim-analysis Version: 1.0.3 The skill bundle implements a legitimate financial analysis pipeline for US stocks based on the CANSLIM methodology. The Python scripts (quantitative_analyzer.py, final_process.py, and pdf_report_generator.py) use standard libraries like yfinance and pandas to fetch market data and generate reports, with no evidence of malicious intent, data exfiltration, or unauthorized system access. The SKILL.md instructions are well-scoped to the stated task and do not contain prompt-injection attempts or instructions to bypass security boundaries.
Capability Assessment
Purpose & Capability
Name/description (CANSLIM hybrid analysis) match the included Python scripts and requirements: quantitative screening (yfinance, pandas), report generation (reportlab), and an AI enrichment step described in SKILL.md. The declared no-env-vars / no-binaries requirement is proportional.
Instruction Scope
SKILL.md gives concrete steps: create venv, pip install requirements.txt, run quantitative_analyzer.py, have the agent perform AI enrichment on intermediate_canslim.json, run final_process.py to produce outputs. The instructions do not ask the agent to read unrelated system files or secrets. The AI enrichment step is intentionally delegated to the agent (no separate implemented enrichment script), which matches the skill design.
Install Mechanism
No automated install spec is present (instruction-only install via venv + pip -r Scripts/requirements.txt). Dependencies are standard packages from PyPI and the requirements file is included and pinned; nothing is downloaded from arbitrary URLs or executed from untrusted hosts.
Credentials
The skill requests no environment variables or credentials. The code performs only public-data network requests (Wikipedia for S&P tickers, Yahoo Finance via yfinance). There are no hardcoded secret keys or unrelated service tokens.
Persistence & Privilege
The skill does not request always:true and does not attempt to modify other skills or global agent configuration. It writes outputs and a local log file (canslim_analysis.log) and creates Scripts/out/ for PDFs — typical for a reporting pipeline.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install canslim-analysis
  3. After installation, invoke the skill by name or use /canslim-analysis
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.3
- All expected and generated files are now specified to be within the Scripts/ directory for better organization. - All file paths in the execution instructions have been updated to reflect the Scripts/ directory. - Dependency installation, script execution, intermediate, and output files are now referenced with the Scripts/ prefix for clarity and consistency. - No changes to the CANSLIM process logic or schema—directory and path specification only.
v1.0.2
- Added professional PDF report generation with analysis and formatted tables (via pdf_report_generator.py). - Now requires and verifies presence of pdf_report_generator.py. - Output includes attaching a CANSLIM PDF report (out/canslim_report_{date}.pdf) on successful analysis. - Updated execution instructions and output format to reflect PDF delivery alongside the JSON report. - Retired the outdated spec/python_spec.md file.
v1.0.1
- Initial public release of the CANSLIM Hybrid Analyzer skill. - Provides end-to-end CANSLIM analysis on US stocks via a modular Python pipeline, combining quantitative screening with OpenClaw AI qualitative checks. - Enforces a strict JSON schema at each stage for full auditability and deterministic handoffs. - Outputs a final ranked shortlist of top CANSLIM candidates, including transparent met/missed criteria and AI catalyst commentary. - Includes robust execution and failure handling instructions, with detailed process and output formatting guidance.
Metadata
Slug canslim-analysis
Version 1.0.3
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 3
Frequently Asked Questions

What is canslim-analysis?

Executes a hybrid quantitative and qualitative CANSLIM analysis on US stocks using a fixed schema and a modular Python pipeline, returning a ranked shortlist. It is an AI Agent Skill for Claude Code / OpenClaw, with 285 downloads so far.

How do I install canslim-analysis?

Run "/install canslim-analysis" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is canslim-analysis free?

Yes, canslim-analysis is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does canslim-analysis support?

canslim-analysis is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created canslim-analysis?

It is built and maintained by lkmsteven (@lkmsteven); the current version is v1.0.3.

💬 Comments