Praxis
This document bridges analysis and action. It describes where Ghost’s knowledge meets trading practice, and how the system learns from experience.
The Decision Boundary
Ghost outputs end at a clear boundary:
Ghost Domain │ Human Domain
────────────────────────────────┼────────────────────────────────
Levels with confluence │ Which level to enter at
Director alignment/conflict │ How to weight disagreement
Zone status (IN_PRIMARY, etc) │ Whether to act on status
R:R at each zone │ Position size per R:R
Flags (earnings, gamma, etc) │ What the flags mean for me
Ghost presents structured data. The trader applies context, risk tolerance, and judgment.
Session Workflow
Pre-Session
# Run full analysis on watchlist (20 LLM calls each)
ghost run VST
ghost run META
ghost run AMZN
This populates the KB with Market Aggregator output: entry zones, targets, stops, flags.
Pre-Market
# Check for setups across watchlist (zero API calls)
ghost scout scan
# If holding a position, activate defense mode
ghost run VST --entry 159.71
Scout surfaces actionable setups from KB. Defense mode shifts analysis from “where to enter” to “what to do with position.”
During Session
# Monitor for intraday signals
ghost intraday VST
# Re-scan if prices moved
ghost scout scan
Intraday analysis detects gaps, sweeps, opening range breaks, volume anomalies.
End of Day
# Verify predictions against actual outcomes
ghost verify VST
# Review guardrail accuracy
ghost guardrails
This feeds the self-correction loop. Predictions are marked hit/miss.
Execution Modes
Ghost surfaces two modes. A setup can be scalp, swing, both, or neither.
| Mode | Timeframe | Stop Logic | Target Logic | R:R Threshold |
|---|---|---|---|---|
| Scalp | Minutes to hours | OR low, air pocket | VWAP, POC, mean reversion | >1.0 |
| Swing | Days to weeks | Below structural level | Fib extensions, prior highs | >1.5 |
Mode Detection
| Situation | What Ghost Shows |
|---|---|
| Overdone dip, not at structure | SCALP only — mean reversion trade |
| At structure, not overdone | SWING only — wait for level test |
| Overdone dip INTO structure | BOTH — scalp now, swing if continues |
| Neither overdone nor at structure | WAIT — no setup |
See ONTOLOGY.md Execution Mode Concepts for full treatment.
Zone-Based Trading
Entry zones cascade:
primary (highest) > secondary > aggressive (lowest) > stop_loss
All three zones required. Stop must be below aggressive.
Zone Status Actions
Scout classifies current price vs zones:
| Zone Status | Meaning | Typical Action |
|---|---|---|
IN_PRIMARY | Price inside primary zone | Entry candidate |
IN_SECONDARY | Price inside secondary zone | Entry candidate (deeper dip) |
IN_AGGRESSIVE | Price at panic zone | Entry candidate (low conviction) |
JUST_ABOVE_PRIMARY | Within 2% above primary | Wait for zone |
IN_GAP | Between zones | No confluence — wait |
EXTENDED | >2% above primary | No setup currently |
BELOW_ZONES | Below all zones | Thesis in question |
R:R Calculation
R:R = (scalp_target - zone_midpoint) / (zone_width / 2)
Ghost calculates R:R at each zone. The trader decides minimum acceptable R:R.
Position Management
Defense Mode
When holding a position, pass --entry to shift analysis:
ghost run VST --entry 159.71
This activates guardrails:
| Guardrail | What It Checks |
|---|---|
| Sweep completion | Is there an active sweep trapping your entry? |
| Max pain proximity | Is price being pinned near expiration? |
| Catalyst override | Is there a binary event overriding technicals? |
| AH momentum | Is extended hours action signaling tomorrow’s direction? |
Exit Optimization
Defense mode shifts from entry zones to exit guidance:
| Recommendation | Meaning |
|---|---|
hold_for_target | Structure supports continuation |
wait_for_entry | Underwater but thesis intact |
exit_now | Structure broken, cut loss |
hold_with_caution | Mixed signals, tight stops |
Post-Mortem Methodology
When analysis fails, trace backwards:
Outcome → Aggregator output → Director synthesis → Agent analysis → Data input
Error Categories
| Category | Where to Look | Fix |
|---|---|---|
| Data error | Tools returned wrong/stale data | Fix tool, refresh data source |
| Agent misread | Agent misinterpreted correct data | Adjust agent prompt hermeneutics |
| Director misynth | Directors disagreed, wrong one weighted | Adjust director synthesis logic |
| Aggregator artifact | Aggregator introduced bias | Remove from aggregator constraints |
| Narrative attribution | Agent explained price move by citing headline, but flow moved first — the headline was the label, not the cause | Apply narrative forensics: trace the 5 observable channels (state logistics, actor behavior, counterparty behavior, risk pricing, speculative positioning) to find when the market actually knew. See NARRATIVE_FORENSICS.md |
| Human override | Trader ignored good analysis | Not a system error |
Correction Process
- Identify — Which layer failed?
- Isolate — Test that layer in isolation (
ghost test [stack]) - Correct — Adjust prompt or logic
- Validate — Zero-cost validation (
ghost prompt render) - Verify — Run full analysis, compare to known-good
Backtest Process
For systematic evaluation:
1. Scorecard
Track predictions systematically:
| Field | Purpose |
|---|---|
| Ticker | What was analyzed |
| Date | When |
| Zone | Primary/secondary/aggressive |
| Entry price | Where Ghost said to enter |
| Target | Where Ghost said to exit |
| Actual outcome | What happened |
| Hit/Miss | Did it work? |
| Conditions | Market conditions at time |
2. Audit
Group by condition to find systematic errors:
"Multi-TF squeeze" predictions: 12 total, 4 hits = 33% accuracy
"Near max pain on Friday" predictions: 8 total, 7 hits = 87% accuracy
3. Correction
If a condition shows systematic error, adjust:
- Agent prompt (hermeneutics)
- Director synthesis weighting
- Aggregator output constraints
4. Replay Validation
Re-run corrected prompts against historical data:
ghost prompt render [agent] --ticker VST
Zero-cost validation of prompt changes.
5. Live Verification
After correction, track next N live predictions for that condition. If accuracy improves, correction is valid.
Resource-Aware Practice
Ghost runs cost API quota. Practice with awareness.
| Command | LLM Calls | Use Case |
|---|---|---|
ghost run | ~10 | Full pipeline — use sparingly |
ghost test news | 7-8 | Test news stack changes |
ghost test technical | ~10 | Test technical stack changes |
ghost test strategist --use-cache | 1 | Test aggregator with cached inputs |
ghost test vst-module | 1 | Test VST module prompt changes in isolation (uses cached upstream theses + live env data) |
ghost scout scan | 0 | KB-only watchlist scan |
ghost prompt render | 0 | Zero-cost prompt validation (includes vst-module for VST module template) |
Quota Rules
- Never run
ghost runmore than twice per development session for testing - For prompt changes, use
ghost test [stack]in isolation - For syntax validation, use
ghost prompt renderat zero cost - If quota hits 429, stop immediately — do not retry
- Batch changes, verify together
Feedback Integration
Ghost’s feedback loop:
Run → Predict → Verify → Learn → Adjust → Run
| Stage | What Happens |
|---|---|
| Run | Analysis produces prediction |
| Predict | Prediction saved with conditions |
| Verify | Auto-verify after 1hr via yfinance |
| Learn | Accuracy stats updated with decay weighting |
| Adjust | Directors see track record in prompts |
| Run | Next analysis informed by history |
The system doesn’t just predict — it learns from predictions.
Scout Cold-Start Behavior
Scout scoring has two effective regimes depending on prediction history:
Structural-only (cold start): When fewer than 3 verified predictions match the current condition combination, get_multi_condition_accuracy() returns accuracy_pct: None, which maps to a 1.0x multiplier — no adjustment. Scout scores using structural factors only: zone status, R:R, conviction, director bias.
Full scoring (warm): Once enough verified predictions exist, Scout applies condition-aware accuracy weighting. The system degrades gracefully — it progressively relaxes conditions (dropping lowest-priority first: day_of_week, then gap proximity, then director confidence, etc.) until it finds at least 3 matching predictions. This means partial condition matches activate before full matches do.
Bootstrapping a new ticker requires multiple ghost run calls to build prediction history, plus time for auto-verification (predictions must be >= 1hr old). This has quota cost implications — budget accordingly. The structural-only scores are still useful; condition accuracy adds refinement, not the foundation.
Related Documentation
EPISTEMOLOGY.md— How Ghost forms and validates knowledgeETHICS.md— What Ghost must and must not doONTOLOGY.md— What the concepts areDAY_DESK_REFERENCE.md— Day desk tool catalogPEDAGOGICAL.md— How to learn this system