[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M783GHAJMK1BX8F8R3J2F4W1":3,"skill-same:01M783GHAJMK1BX8F8R3J2F4W1":50},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":28,"commitSha":29,"skillDirectory":30,"forksCount":31,"repositoryHtmlUrl":32,"repositoryHomepageUrl":6,"ownerHtmlUrl":33,"ownerBlogUrl":34,"ownerDescription":6,"updatedAt":35,"install":36,"resources":49},"01M783GHAJMK1BX8F8R3J2F4W1","position-journal",null,"The position book is the journal: every confirmed swap writes it, an entry carries its plan, a sell its close reason; P&L read from defi_data.positions and \u002Ftrade status (average cost, computed by the verb, never by hand), reconcile, retire, unknown is never zero, and never summing books.","theselfruleorg\u002Fpolyrob","theselfruleorg","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F128891129?v=4","01M783D1MFDP1D5ZXSNZMKHARH","01M783D1NEE9ATD39KJYCRR09J",12,"MIT","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fdata\u002Fprompts\u002Fskills\u002Fposition-journal\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: position-journal\ndescription: 'The position book is the journal: every confirmed swap writes it, an entry carries its plan, a sell its close reason; P&L read from defi_data.positions and \u002Ftrade status (average cost, computed by the verb, never by hand), reconcile, retire, unknown is never zero, and never summing books.'\nlicense: MIT\nmetadata:\n  polyrob-when: 'Recording fills and reading P&L of positions'\n  polyrob-priority: '2'\n  polyrob-triggers: '{\"tool_ids\":[\"defi_trade\",\"defi_data\"]}'\n  polyrob-version: '6'\n---\n# Position Journal — the book is the journal\n\nThe money rail keeps ONE position book (`open_positions`). You do not write\nit: every CONFIRMED swap records its position there, sized from the guard's\nsimulation. The chain is the truth; the book must match it. Every figure the owner\nor the public sees is rendered from this book. Do not keep a second record — no\nmarkdown ledger, no trade table in the knowledge base, no running total in a\nnote. A second record is what disagreed with the chain before.\n\n## What the book holds\n\n- **Positions.** A confirmed `swap` (EVM) or `solana_swap` records the size\n  from the vetted simulation (`SIMULATED balance change, final fill not\n  measured`) and the cost basis in USD. Each\n  sell books its realized P&L. The cost method is AVERAGE COST: a partial sell\n  reduces the basis in proportion to the size sold. The native coin or the\n  wrapped native bought WITH A STABLE is a position too; the same coin received\n  from an exit is not. `defi_data.positions(chain=…)` reads the book and does every sum for\n  you: size, basis, price, value, unrealized P&L in USD and %, realized P&L,\n  and the high-water price. The owner sees the same basis as \"Entry\" in\n  `\u002Fbook`.\n- **The plan.** Inside a trading mandate every entry carries its `plan`\n  (thesis, confidence, invalidation, preset); it is stored beside the book row\n  and the exit runs follow it. Write the WHY there, not in a note.\n- **The close reason.** Every sell says why it closes with `close_reason`\n  (`exits` lists the values). It reaches the realized row, and `\u002Ftrade status`\n  shows the reasons beside the realized P&L.\n- **Reconcile.** `defi_data.reconcile(chain=…)` compares the book with on-chain\n  balances and returns a VERDICT (`CLEAN`, `DISAGREEMENT`, `UNVERIFIED`). Its\n  output is authoritative over your memory and over any earlier summary.\n- **Basis unknown.** A position has NO basis when it was inherited or bought by\n  a swap the rail could not value. `positions` then says \"basis unknown\" and\n  gives no P&L. Unknown is not zero: never write $0 as its cost, and never\n  compute a P&L for it yourself.\n- **What the book does not hold:** fees per trade (so P&L is gross of gas),\n  and venue positions (Hyperliquid, Polymarket).\n\n## The procedure\n\n1. **Verify every fill** (see `post-trade-verify`): chain, address, side,\n   measured quantity, gas, tx hash. The quantity is the measured chain delta\n   (`portfolio` before and after) — never the quoted output, never the book's\n   simulated size, and never the \"fill\" a tool result reports.\n2. **Read P&L from the verbs.** `defi_data.positions` per chain; `\u002Ftrade\n   status` for a mandate (allocation used, PROTECTED\u002FUNPROTECTED, realized\n   gross, the mandate's LLM cost). Repeat their figures as written. Do not keep\n   lots by hand, do not use FIFO, and do not compute or convert a money figure\n   yourself. If a verb says `unknown` or \"at least\", say the same.\n3. **Reconcile before any claim** about the book, before a new entry on the\n   same token, and after anything that looked wrong. A record can say \"Open\n   positions: NONE\" while the chain holds positions; never publish a book\n   claim you did not reconcile.\n4. **Holdings the book does not explain** are either a position bought outside\n   the money rail or something someone sent you — the rule for those is\n   \"Tokens you did not buy\" in `trade-execution`. Say which in your report.\n   `reconcile` names an unpriced token the book does not hold as\n   `unsolicited`: it is not an issue.\n5. **A book row the chain does not back:** if the measured balance is zero or\n   dust, retire it with `defi_data.retire_row` (it refuses unless the chain\n   proves it). A loss to close is the owner's `\u002Fwriteoff`.\n6. **One symbol, two contracts:** if `reconcile` prints the collision warning,\n   the book row's address decides which contract is yours — never the symbol.\n7. **Never sum books.** Each chain, each wallet, and each venue keeps its own\n   rows; a treasury figure names what it includes.\n\n## If a tool is missing\n\nFollow `harness-manual`; do the read steps you can, and never work around a\nmissing verb with a raw `call`, a browser dapp or another agent.\n\n## Related\n\n`post-trade-verify`, `exits`, `trading-mandate`. To check SOMEONE ELSE's wallet, use\n`defi_data.wallet_holdings(address=…, chain=…)` — `positions` and `portfolio`\nread only this agent's own book.\n","# Position Journal — the book is the journal\n\nThe money rail keeps ONE position book (`open_positions`). You do not write\nit: every CONFIRMED swap records its position there, sized from the guard's\nsimulation. The chain is the truth; the book must match it. Every figure the owner\nor the public sees is rendered from this book. Do not keep a second record — no\nmarkdown ledger, no trade table in the knowledge base, no running total in a\nnote. A second record is what disagreed with the chain before.\n\n## What the book holds\n\n- **Positions.** A confirmed `swap` (EVM) or `solana_swap` records the size\n  from the vetted simulation (`SIMULATED balance change, final fill not\n  measured`) and the cost basis in USD. Each\n  sell books its realized P&L. The cost method is AVERAGE COST: a partial sell\n  reduces the basis in proportion to the size sold. The native coin or the\n  wrapped native bought WITH A STABLE is a position too; the same coin received\n  from an exit is not. `defi_data.positions(chain=…)` reads the book and does every sum for\n  you: size, basis, price, value, unrealized P&L in USD and %, realized P&L,\n  and the high-water price. The owner sees the same basis as \"Entry\" in\n  `\u002Fbook`.\n- **The plan.** Inside a trading mandate every entry carries its `plan`\n  (thesis, confidence, invalidation, preset); it is stored beside the book row\n  and the exit runs follow it. Write the WHY there, not in a note.\n- **The close reason.** Every sell says why it closes with `close_reason`\n  (`exits` lists the values). It reaches the realized row, and `\u002Ftrade status`\n  shows the reasons beside the realized P&L.\n- **Reconcile.** `defi_data.reconcile(chain=…)` compares the book with on-chain\n  balances and returns a VERDICT (`CLEAN`, `DISAGREEMENT`, `UNVERIFIED`). Its\n  output is authoritative over your memory and over any earlier summary.\n- **Basis unknown.** A position has NO basis when it was inherited or bought by\n  a swap the rail could not value. `positions` then says \"basis unknown\" and\n  gives no P&L. Unknown is not zero: never write $0 as its cost, and never\n  compute a P&L for it yourself.\n- **What the book does not hold:** fees per trade (so P&L is gross of gas),\n  and venue positions (Hyperliquid, Polymarket).\n\n## The procedure\n\n1. **Verify every fill** (see `post-trade-verify`): chain, address, side,\n   measured quantity, gas, tx hash. The quantity is the measured chain delta\n   (`portfolio` before and after) — never the quoted output, never the book's\n   simulated size, and never the \"fill\" a tool result reports.\n2. **Read P&L from the verbs.** `defi_data.positions` per chain; `\u002Ftrade\n   status` for a mandate (allocation used, PROTECTED\u002FUNPROTECTED, realized\n   gross, the mandate's LLM cost). Repeat their figures as written. Do not keep\n   lots by hand, do not use FIFO, and do not compute or convert a money figure\n   yourself. If a verb says `unknown` or \"at least\", say the same.\n3. **Reconcile before any claim** about the book, before a new entry on the\n   same token, and after anything that looked wrong. A record can say \"Open\n   positions: NONE\" while the chain holds positions; never publish a book\n   claim you did not reconcile.\n4. **Holdings the book does not explain** are either a position bought outside\n   the money rail or something someone sent you — the rule for those is\n   \"Tokens you did not buy\" in `trade-execution`. Say which in your report.\n   `reconcile` names an unpriced token the book does not hold as\n   `unsolicited`: it is not an issue.\n5. **A book row the chain does not back:** if the measured balance is zero or\n   dust, retire it with `defi_data.retire_row` (it refuses unless the chain\n   proves it). A loss to close is the owner's `\u002Fwriteoff`.\n6. **One symbol, two contracts:** if `reconcile` prints the collision warning,\n   the book row's address decides which contract is yours — never the symbol.\n7. **Never sum books.** Each chain, each wallet, and each venue keeps its own\n   rows; a treasury figure names what it includes.\n\n## If a tool is missing\n\nFollow `harness-manual`; do the read steps you can, and never work around a\nmissing verb with a raw `call`, a browser dapp or another agent.\n\n## Related\n\n`post-trade-verify`, `exits`, `trading-mandate`. To check SOMEONE ELSE's wallet, use\n`defi_data.wallet_holdings(address=…, chain=…)` — `positions` and `portfolio`\nread only this agent's own book.\n",{"name":5,"license":14,"metadata":23,"description":7},{"polyrob-when":24,"polyrob-version":25,"polyrob-priority":26,"polyrob-triggers":27},"Recording fills and reading P&L of positions","6","2","{\"tool_ids\":[\"defi_trade\",\"defi_data\"]}","main","3a595c0e3db5aa91acc53dd80673c4d80e0721d1","data\u002Fprompts\u002Fskills\u002Fposition-journal",2,"https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg","https:\u002F\u002Ftheselfrule.org","2026-11-14 16:54:43",{"source":8,"skillName":5,"commands":37,"prompt":47,"zipAvailable":48},[38,41,44],{"tool":39,"command":40},"npx","npx skills add theselfruleorg\u002Fpolyrob --skill position-journal",{"tool":42,"command":43},"bunx","bunx skills add theselfruleorg\u002Fpolyrob --skill position-journal",{"tool":45,"command":46},"pnpm","pnpm dlx skills add theselfruleorg\u002Fpolyrob --skill position-journal","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fdata\u002Fprompts\u002Fskills\u002Fposition-journal\u002FSKILL.md",true,[],[51,58,65,72,79,86],{"skillNo":52,"name":53,"nameZh":6,"description":54,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":55,"categories":56,"keywords":57,"publishedAt":18},"01M783NSEPG1S13E7W3GEQMG6J","echo-basics","How to use the echo tool from the echo fixture pack.","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fpacks\u002Fecho\u002Fpolyrob_echo\u002Fskills\u002Fecho-basics\u002FSKILL.md",[],[],{"skillNo":59,"name":60,"nameZh":6,"description":61,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":62,"categories":63,"keywords":64,"publishedAt":18},"01M783NM911CND5PQCYDHA9GGV","x-engagement","Operate X account communication on the API rail (the captured-browser rail only where the owner chose it)—read inboxes, post\u002Freply, send DMs, set up the account, with the real write gates and completion evidence","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fpacks\u002Fx\u002Fpolyrob_x\u002Fskills\u002Fx-engagement\u002FSKILL.md",[],[],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":18},"01M783NGQ43PGVT6F9XQR4ZNP2","social-discovery","Discover public X\u002Fsocial accounts and conversations with AnySite first (anysite_describe, then anysite_api), using native X account reads where they are authoritative and preserving write gates","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fpacks\u002Fx\u002Fpolyrob_x\u002Fskills\u002Fsocial-discovery\u002FSKILL.md",[],[],{"skillNo":73,"name":74,"nameZh":6,"description":75,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":76,"categories":77,"keywords":78,"publishedAt":18},"01M783NDAEPJT10SD3DNR56H96","polymarket-trading","GATED: place\u002Fcancel Polymarket orders. Owner-only, read-first, >$500 confirmation gate; references crypto-trading-safety","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fpacks\u002Fmarkets\u002Fpolyrob_markets\u002Fskills\u002Fpolymarket-trading\u002FSKILL.md",[],[],{"skillNo":80,"name":81,"nameZh":6,"description":82,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":83,"categories":84,"keywords":85,"publishedAt":18},"01M783N8GADTQMKKBQT4Z3JJ84","polymarket-portfolio-review","Read the configured Polymarket account's positions and trade history from the public Data API (no address parameter); summarize exposure and P&L","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fpacks\u002Fmarkets\u002Fpolyrob_markets\u002Fskills\u002Fpolymarket-portfolio-review\u002FSKILL.md",[],[],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":9,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":92,"publishedAt":18},"01M783N5KTTTRRRSM7XY8SY4NF","polymarket-market-research","Read Polymarket markets (discover, details, price as implied probability, orderbook, spread, volume) with no wallet","https:\u002F\u002Fgithub.com\u002Ftheselfruleorg\u002Fpolyrob\u002Fblob\u002Fmain\u002Fpacks\u002Fmarkets\u002Fpolyrob_markets\u002Fskills\u002Fpolymarket-market-research\u002FSKILL.md",[],[]]