Skip to content
SlashClone
Made by@qtrader

Trade journal

@qtrader/trade-journal

Keep a trading journal that actually teaches you something. Log each trade with its setup, thesis, emotions, plan adherence, and mistakes in a CSV, then get a weekly review that finds what is working and what is leaking money by setup, time of day, holding period, emotion, and plan adherence. Not financial advice.

SkillTradingv1.0.0 (latest)Tested
Activity
New: be the first to try it
  1. 1{
  2. 2 "name": "trade-journal",
  3. 3 "owner": "qtrader",
  4. 4 "version": "1.0.0",
  5. 5 "type": "skill",
  6. 6 "description": "Keep a trading journal that actually teaches you something. Log each trade with its setup, thesis, emotions, plan adherence, and mistakes in a CSV, then get a weekly review that finds what is working and what is leaking money by setup, time of day, holding period, emotion, and plan adherence. Not financial advice.",
  7. 7 "category": "trading",
  8. 8 "license": "MIT",
  9. 9 "compat": ["claude-code"],
  10. 10 "permissions": {
  11. 11 "shell": ["node scripts/journal.mjs", "node scripts/selftest.mjs"],
  12. 12 "files": { "read": ["./journal/**"], "write": ["./journal/**", "./out/**"] }
  13. 13 },
  14. 14 "tests": {
  15. 15 "cases": [
  16. 16 {
  17. 17 "name": "P&L, buckets, patterns, and CSV writing match the hand checks",
  18. 18 "inputs": {},
  19. 19 "checks": [{ "type": "command_exits_zero", "command": "node scripts/selftest.mjs" }]
  20. 20 },
  21. 21 {
  22. 22 "name": "weekly review of the example journal finds the edge and the leak",
  23. 23 "inputs": {},
  24. 24 "checks": [
  25. 25 { "type": "command_exits_zero", "command": "node scripts/journal.mjs review --file examples/trades.csv --out out/review" },
  26. 26 { "type": "file_contains", "path": "out/review.md", "text": "Closed trades 17 | Win rate 53% | Net P&L $763.40" },
  27. 27 { "type": "file_contains", "path": "out/review.md", "text": "Setup: \"opening range breakout\" is your best" },
  28. 28 { "type": "file_contains", "path": "out/review.md", "text": "Setup: \"vwap fade\" is costing you" },
  29. 29 {
  30. 30 "type": "output_matches_schema",
  31. 31 "path": "out/review.json",
  32. 32 "schema": {
  33. 33 "type": "object",
  34. 34 "required": ["overall", "groups", "patterns", "open_trades"],
  35. 35 "properties": {
  36. 36 "overall": { "type": "object", "properties": { "n": { "const": 17 }, "wins": { "const": 9 } } },
  37. 37 "open_trades": { "type": "array", "minItems": 1, "maxItems": 1 },
  38. 38 "patterns": { "type": "array", "minItems": 4 }
  39. 39 }
  40. 40 }
  41. 41 }
  42. 42 ]
  43. 43 },
  44. 44 {
  45. 45 "name": "logs new trades to a fresh journal and reviews them",
  46. 46 "inputs": {},
  47. 47 "checks": [
  48. 48 {
  49. 49 "type": "command_exits_zero",
  50. 50 "command": "node scripts/journal.mjs add --file journal/trades.csv --symbol xyz --side long --qty 100 --entry 20 --exit 21 --stop 19.5 --fees 1 --opened \"2026-11-02 09:40\" --closed \"2026-11-02 10:10\" --setup \"opening range breakout\" --thesis \"Gap held, volume, clean break\" --emotion-entry calm --followed-plan y"
  51. 51 },
  52. 52 {
  53. 53 "type": "command_exits_zero",
  54. 54 "command": "node scripts/journal.mjs add --file journal/trades.csv --symbol xyz --side short --qty 50 --entry 21.5 --exit 21.9 --stop 22 --opened \"2026-11-02 12:05\" --closed \"2026-11-02 12:30\" --setup \"vwap fade\" --emotion-entry bored --followed-plan n --mistakes \"entered early\""
  55. 55 },
  56. 56 { "type": "file_contains", "path": "journal/trades.csv", "text": "\"Gap held, volume, clean break\"" },
  57. 57 { "type": "command_exits_zero", "command": "node scripts/journal.mjs review --file journal/trades.csv --out out/week" },
  58. 58 { "type": "file_contains", "path": "out/week.md", "text": "Closed trades 2 | Win rate 50% | Net P&L $79.00" }
  59. 59 ]
  60. 60 }
  61. 61 ]
  62. 62 }