learnings

A local file-based archive for recording and reusing notes about solved troubleshooting problems.

In plain words
What is it for?
Use it to find earlier troubleshooting notes, add durable notes after solving an issue, and inspect or repair the archive's files, links, environment settings, and scheduled tasks.
Why use it?
It helps you check whether a similar problem was solved before without relying on chat history. It also requires checking current files, logs, and system state before applying an old lesson.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/firstp1ck/pi-coding-agent-forge/learnings
Any agent
npx skills add Firstp1ck/pi-coding-agent-forge --skill learnings
Clone the repo
git clone --depth 1 https://github.com/Firstp1ck/pi-coding-agent-forge

Made for: Claude Code, Codex.

Per session 54 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,054 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00054 $0.01054
Opus 5 $0.00027 $0.00527
Sonnet 5 $0.00011 $0.00211
Haiku 4.5 $0.00005 $0.00105

Measured 3d ago against content hash 495e6d532a03, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

learnings scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

pi-package-learnings/skills/learnings/SKILL.md · 135 lines

How it starts

The opening of the file, as written. The whole thing — 135 lines — stays where its author put it; the contents beside it link to each section on GitHub.

LEARNINGS

This skill manages and uses Firstpick's durable troubleshooting LEARNINGS archive.

The archive is not chat memory. It is a local, file-based knowledge base of short solved-issue notes plus generated indexes and summaries.

When to use

Use this skill when:

  • a troubleshooting issue looks similar to something solved before
  • the user asks about LEARNINGS, /ret-LEARNINGS, or /sum-LEARNINGS
  • a troubleshooting session ended with a real solution and should be recorded
  • the LEARNINGS symlink/env/timer/scripts need inspection or repair

Do not blindly apply a past solution. Always verify against current files, commands, logs, and system state.

Path resolution

Resolve the archive root in this order:

  1. Source ~/.pi/agent/learnings.env if present and use $LEARNINGS_DIR.
  2. Otherwise use the stable symlink ~/.pi/agent/LEARNINGS.
  3. Otherwise ask before creating a new archive.

Expected current value on Firstpick's system:

/mnt/SSD_NVME/LEARNINGS

Portable shell snippet:

source "$HOME/.pi/agent/learnings.env" 2>/dev/null || true
LEARNINGS_DIR="${LEARNINGS_DIR:-$HOME/.pi/agent/LEARNINGS}"

Retrieval workflow

  1. Resolve LEARNINGS_DIR.
  2. Read $LEARNINGS_DIR/LEARNINGS-SUMMARY.md.
  3. Identify relevant entries.
  4. Read the referenced source or archive file for each relevant entry.
  5. Apply the lesson only after verifying the current system/repo state.
  6. In the final answer, briefly cite which LEARNINGS files influenced the solution.

If LEARNINGS-SUMMARY.md is missing or stale, run:

~/.pi/agent/bin/learnings-summary

or, from this skill directory, using paths relative to the skill root:

../../scripts/sync-learnings.py
../../scripts/summarize-learnings.py

Adding a learning

This is an implicit completion requirement, not an optional reminder.

At the end of every troubleshooting/configuration/repair task where a real solution was found, automatically create or update one concise LEARNINGS .md note before the final answer. Do not wait for the user to ask. This applies especially when this skill was used for inspection, repair, cleanup, setup, repeated-issue retrieval, or LEARNINGS maintenance.

Read the full file on GitHub · 135 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 135 lines · 54 tokens per session scan A 495e6d532a03

Subscribe to this mod's changes

learnings is a skill published in the GitHub repository Firstp1ck/pi-coding-agent-forge (74 stars, last pushed 3d ago), licensed MIT. It adds 54 tokens to every session and 1,054 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.