codecall 1.2.3 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (23) hide show
  1. package/README.md +104 -207
  2. package/package.json +1 -1
  3. package/plugins/codecall/.claude-plugin/plugin.json +6 -2
  4. package/plugins/codecall/.codex-plugin/plugin.json +13 -4
  5. package/plugins/codecall/agents/codecall-planner.md +6 -1
  6. package/plugins/codecall/skills/codecall/SKILL.md +96 -95
  7. package/plugins/codecall/skills/codecall/references/backend-map/api.md +113 -0
  8. package/plugins/codecall/skills/codecall/references/backend-map/architecture.md +65 -0
  9. package/plugins/codecall/skills/codecall/references/backend-map/async.md +81 -0
  10. package/plugins/codecall/skills/codecall/references/backend-map/auth.md +97 -0
  11. package/plugins/codecall/skills/codecall/references/backend-map/caching.md +65 -0
  12. package/plugins/codecall/skills/codecall/references/backend-map/data.md +144 -0
  13. package/plugins/codecall/skills/codecall/references/backend-map/http.md +97 -0
  14. package/plugins/codecall/skills/codecall/references/backend-map/index.md +165 -0
  15. package/plugins/codecall/skills/codecall/references/backend-map/observability.md +65 -0
  16. package/plugins/codecall/skills/codecall/references/backend-map/ops.md +129 -0
  17. package/plugins/codecall/skills/codecall/references/backend-map/quality.md +81 -0
  18. package/plugins/codecall/skills/codecall/references/backend-map/realtime.md +65 -0
  19. package/plugins/codecall/skills/codecall/references/backend-map/reliability.md +65 -0
  20. package/plugins/codecall/skills/codecall/references/backend-map/scaling.md +81 -0
  21. package/plugins/codecall/skills/codecall/references/backend-map/security.md +97 -0
  22. package/plugins/codecall/skills/codecall/references/backend-map/storage.md +81 -0
  23. package/plugins/codecall/skills/codecall/references/receipt-template.html +71 -0
package/README.md CHANGED
@@ -1,30 +1,44 @@
1
1
  # codecall
2
2
 
3
- [**Website**](https://codecall-theta.vercel.app/) · [npm](https://www.npmjs.com/package/codecall) · [GitHub](https://github.com/GAURAV-1313/codecall)
3
+ `npx skills add GAURAV-1313/codecall` · Claude Code, Codex, Cursor, Gemini CLI, OpenCode, Kiro, Copilot · no API key, nothing uploaded
4
4
 
5
- **codecall teaches you the code you just wrote.**
5
+ ![A codecall receipt: the change in a line, each idea marked could explain or could not, a score of 3 of 4](https://raw.githubusercontent.com/GAURAV-1313/codecall/main/docs/receipt.png)
6
6
 
7
- After you (or your AI coding assistant) finish building something, codecall
8
- turns that work into a quick, friendly quiz — so you actually understand what
9
- was built, not just that it works. It runs inside Codex or Claude Code, the
10
- AI coding tools you already use. No extra app, no signup, no API key.
7
+ **codecall quizzes you on the code the agent just wrote.** When an
8
+ implementation lands, it offers a four-minute session: it teaches the 2 to 4
9
+ ideas behind the change using your actual code, checks each one with two
10
+ questions, and ends with a one-page receipt you can keep or post. No API key,
11
+ nothing uploaded, nothing remembered unless you keep the receipt.
11
12
 
12
- **Why use it?** It's easy to accept code from an AI assistant without fully
13
- understanding it. codecall closes that gap: right after something is built,
14
- it teaches you the 2–4 key ideas behind it, asks a couple of simple questions
15
- to check your understanding, and tells you what to double check before you
16
- reuse the same pattern elsewhere.
13
+ ## Install
17
14
 
18
- You're always in control — it only starts when you say "yes," and you can
19
- skip it every time if you want.
15
+ ```bash
16
+ npx skills add GAURAV-1313/codecall
17
+ ```
20
18
 
21
- ### What it looks like
19
+ Then type `/codecall` (or `$codecall` in Codex) after your agent finishes
20
+ something. You are always asked **Start Learning / Skip** first.
22
21
 
23
- Say your AI assistant just added login to your app. You type `$codecall` (or
24
- `/codecall`), and this happens:
22
+ Want it to *offer* automatically after meaningful changes, not just when you
23
+ ask? Install the plugin instead; it adds a small local hook that reminds the
24
+ agent to check, and never decides for you:
25
25
 
26
26
  ```text
27
- You: $codecall
27
+ /plugin marketplace add https://github.com/GAURAV-1313/codecall
28
+ /plugin install codecall@codecall
29
+ ```
30
+
31
+ (Codex: `codex plugin marketplace add https://github.com/GAURAV-1313/codecall`
32
+ then `codex plugin add codecall@codecall`. The plugin's command is
33
+ `/codecall:codecall` in Claude Code.) `npm install -g codecall` also works and
34
+ installs the skill for both Codex and Claude Code.
35
+
36
+ ## What a session looks like
37
+
38
+ Say your agent just added login to your app.
39
+
40
+ ```text
41
+ You: /codecall
28
42
 
29
43
  codecall: Implementation completed.
30
44
  Learning opportunity: this adds authentication middleware and a
@@ -42,223 +56,106 @@ You: Heard of it
42
56
 
43
57
  codecall: Let's start with why every request now passes through a check
44
58
  before reaching your account routes...
45
- (explains the concept in plain terms, using YOUR actual code)
59
+ (explains the idea in plain terms, using YOUR actual code)
46
60
 
47
61
  Quick check: if someone sends a request without logging in,
48
62
  what should happen?
49
- [ multiple-choice answer ]
50
63
 
51
- You: (pick an answer)
64
+ You: (answer)
52
65
 
53
- codecall: (tells you if you're right, and why — then moves to the next idea)
66
+ codecall: (tells you if you're right, and why, then moves to the next idea)
54
67
 
55
68
  ...
56
69
 
57
- codecall: Session complete.
58
- You learned: authentication middleware, token verification.
59
- Remember: always check the token before touching user data.
60
- Watch out for: forgetting this check on a new route you add later.
61
- ```
62
-
63
- That's the whole product — a short, focused conversation about the code that
64
- was just written, grounded in what actually happened, not a generic
65
- tutorial.
66
-
67
- ### It's not just for auth
68
-
69
- Say your assistant instead added retry logic with exponential backoff around
70
- a flaky payment API call. codecall would recommend a session on *why* retries
71
- need backoff and jitter instead of just trying again immediately, teach that
72
- using your actual retry code, then check whether you can spot when retrying
73
- is the wrong call (like after a non-idempotent request that already went
74
- through). Same short format — a couple of ideas, a couple of questions, a
75
- summary — just grounded in whatever you actually built.
76
-
77
- Or say your assistant added a database index to speed up a slow query.
78
- codecall would recommend a session on *why* that specific index helps — how
79
- the query planner uses it, which column order matters, and when an index
80
- actually hurts (like on a write-heavy table). It would teach that using your
81
- real schema and query, then check whether you can predict which future queries
82
- this index will and won't help. Same short format — a couple of ideas, a
83
- couple of questions, a summary — grounded in the change you just made.
84
-
85
- ## Requirements
86
-
87
- - Codex or Claude Code, already installed.
88
- - No account, no signup, no API key, no internet access needed.
89
-
90
- ## Install it (pick one)
91
-
92
- ### If you use Codex
93
-
94
- ```bash
95
- codex plugin marketplace add https://github.com/GAURAV-1313/codecall
96
- codex plugin add codecall@codecall
97
- ```
98
-
99
- Then restart Codex (or start a new task) and type `$codecall`.
100
-
101
- ### If you use Claude Code
102
-
103
- ```text
104
- /plugin marketplace add https://github.com/GAURAV-1313/codecall
105
- /plugin install codecall@codecall
106
- /reload-plugins
107
- ```
108
-
109
- Then type `/codecall:codecall`.
110
-
111
- ### Either tool, the simple way (no plugin store)
112
-
113
- ```bash
114
- npm install -g codecall
115
- ```
116
-
117
- This installs it for both Codex and Claude Code at once. In Codex, type
118
- `$codecall`. In Claude Code, type `/codecall`.
119
-
120
- > **Note:** codecall isn't in the searchable plugin list inside Codex or
121
- > Claude Code yet — you have to install it with the command above, once.
122
- > After that it works normally every time.
123
- >
124
- > **Note:** the plugin install (not the `npm install -g` path) includes a
125
- > small local script that reminds the agent to check whether a session is
126
- > worth offering, so you may see a one-time "this plugin can run code"
127
- > review prompt during setup. It makes no network calls — see
128
- > [Privacy](#privacy--the-short-version).
129
-
130
- ### How do I know it worked?
131
-
132
- Type the command for whichever way you installed it. You should see
133
- something like this:
134
-
135
- ```text
136
- Implementation completed.
137
- Learning opportunity: <a short reason>
138
- Estimated learning time: <a few minutes>
139
-
140
- Start Learning / Skip
70
+ codecall: Receipt: ./codecall/0007-auth-middleware.html
71
+ Could explain 3 of 4. Keep it, print it, or post it.
141
72
  ```
142
73
 
143
- If you see that, it's working. If nothing happens, try restarting Codex or
144
- Claude Code — a session that was already open won't pick up a fresh install.
145
-
146
- ## How to use it
147
-
148
- 1. Finish some work with Codex or Claude Code, like normal.
149
- 2. Type the command for your install (`$codecall` or `/codecall`).
150
- 3. It asks: **Start Learning or Skip?** Nothing happens until you choose.
151
- 4. If you start: it asks how confident you already are, then teaches one idea
152
- at a time — what it is, why the code needed it, and what breaks without
153
- it — followed by a quick question to check your understanding.
154
- 5. At the end, you get a short summary: what you learned, what to remember,
155
- and any gotchas to watch for if you reuse the same pattern in another
156
- project.
157
-
158
- A typical session covers 2–4 ideas and takes just a few minutes.
159
-
160
- ## Want it to offer to teach you automatically?
161
-
162
- If you installed the **Codex or Claude Code plugin**, this mostly just
163
- works already: a small local check runs after each turn and reminds the
164
- agent to consider offering codecall when something meaningful just
165
- happened — it never decides *for* you, it just makes sure the agent
166
- actually checks. (Only the plugin install gets this; `npm install -g`
167
- doesn't, since it isn't a plugin.)
168
-
169
- Either way, for the strongest guarantee — and the only option for the
170
- `npm install -g` path — copy one small file into your project so the agent's
171
- own instructions always include this check:
172
-
173
- - **Codex:** copy [this file](plugins/codecall/skills/codecall/references/AGENTS.codecall.md)
174
- into your project's `AGENTS.md`.
175
- - **Claude Code:** copy [this file](plugins/codecall/skills/codecall/references/CLAUDE.codecall.md)
176
- into your project's `CLAUDE.md`.
177
-
178
- It's selective on purpose — it only offers after real, meaningful changes
179
- (like a new integration, a security-related change, or an architecture
180
- decision), never for typo fixes, formatting, or routine changes. And it
181
- never teaches without you choosing Start Learning first, automatic or not.
182
-
183
- ## Privacy — the short version
184
-
185
- - No API key, no account, no signup.
186
- - Nothing is uploaded anywhere. It uses the same AI tool and conversation you
187
- already have open — there's no separate model call.
188
- - It doesn't remember anything between sessions or projects. It only avoids
189
- repeating the same suggestion twice in one sitting.
190
- - The plugin install's automatic-check script runs entirely on your machine,
191
- makes no network calls, and only ever adds a text reminder — it can't edit
192
- files or run other commands on its own.
193
- - On the Claude Code plugin, some of the read-only "figure out if this is
194
- worth teaching" work runs in an isolated helper (so it doesn't clutter your
195
- main conversation) — it can only read files, never edit them, and it never
196
- talks to you directly or teaches anything itself.
74
+ The receipt is one screen: the change in a line, each idea marked ✅ could
75
+ explain or ❌ could not, the score, three points to remember, and the edge
76
+ cases to check before you reuse the pattern somewhere else.
77
+
78
+ It is not just for auth. Retry logic with backoff, a new database index, a
79
+ cache layer, a webhook handler: anything with a *why* behind it gets the same
80
+ short format, grounded in what was actually built.
81
+
82
+ ## Why it exists
83
+
84
+ It is easy to accept code from an AI assistant without fully understanding it.
85
+ Reading the diff back is not the same as being asked about it. codecall asks,
86
+ right after the change lands, while the reasons are still fresh, and leaves a
87
+ receipt you can return to.
88
+
89
+ ## How the score is measured
90
+
91
+ Each session covers 2 to 4 ideas. An idea counts as *could explain* when you
92
+ answer both of its checks correctly without a reteach. The score is `N of M`
93
+ ideas, nothing else: no time-on-task, no mastery claim, no guess at what you
94
+ would have known anyway. Earlier receipts in `./codecall/` add a streak line
95
+ (sessions this week, running explain rate) and nothing more.
96
+
97
+ ## Backend concept map
98
+
99
+ For server-side changes, codecall uses a small built-in map of about 80
100
+ backend concepts: HTTP, auth, databases, caching, queues, webhooks, real-time,
101
+ storage, testing and delivery. It gives concepts stable names, orders them by
102
+ what you need to know first, and supplies known misconceptions. You never see
103
+ the map. If a change matches nothing in it, codecall works exactly as before.
104
+
105
+ When you miss a mapped concept, the receipt adds one **Go deeper** line: the
106
+ matching chapter of Sriniously's free
107
+ [Backend from first principles](https://www.youtube.com/playlist?list=PLui3EUkuMTPgZcV0QhQrOcwMPcBCcd_Q1)
108
+ series, plus an official reference (MDN, OWASP, PostgreSQL and similar). The
109
+ map's wording is codecall's own and links to the videos; it does not copy
110
+ them. codecall is not affiliated with or endorsed by the series' creator.
111
+
112
+ ## Privacy
113
+
114
+ - No API key, no account, no signup, no network call.
115
+ - It uses the agent and conversation you already have open. There is no
116
+ separate model call.
117
+ - The receipt is the only thing it writes, into `./codecall/` in your
118
+ project. Delete the folder to forget every session.
119
+ - The plugin's automatic-offer script runs entirely on your machine and only
120
+ ever adds a text reminder; it cannot edit files or run commands.
121
+ - On the Claude Code plugin, the read-only planning step runs in an isolated
122
+ helper so it does not fill your main conversation. It can only read files
123
+ and never talks to you.
197
124
 
198
125
  ## Troubleshooting
199
126
 
200
- **I can't find it when I search inside Codex or Claude Code's plugin list.**
201
- That's expected for now — install it with the command above instead of
202
- searching for it. Once installed, it works like any other plugin.
203
-
204
- **Which command do I type?** `$codecall` in Codex. In Claude Code: `/codecall:codecall`
205
- if you installed the plugin, or plain `/codecall` if you used `npm install -g codecall`.
206
-
207
- **I installed it, but nothing happens.** Restart Codex/Claude Code, or start a
208
- new task — an already-open session won't see a fresh install.
127
+ **Nothing happens after installing.** Restart the agent or start a new
128
+ session; an open session does not pick up a fresh install.
209
129
 
210
- **Does it ever send my code anywhere?** No — see Privacy above.
130
+ **Which command?** `/codecall` after `npx skills add` or `npm install -g`;
131
+ `/codecall:codecall` for the Claude Code plugin; `$codecall` in Codex.
211
132
 
212
- **Why did installing the plugin ask me to review/trust something?** That's
213
- the one-time review for the small local script that powers the "offer to
214
- teach automatically" feature above. It's normal, runs locally, and you can
215
- still decline it — codecall still works, you'll just need to type the
216
- command yourself instead of being offered it.
217
-
218
- **What's the "helper" mentioned in Privacy — is that someone else reading my
219
- code?** No — it's the same AI tool you're already using, just working in an
220
- isolated scratch space so figuring out what's worth teaching doesn't fill up
221
- your main conversation. You won't see it unless you go looking; it only
222
- hands back a short plan.
133
+ **The plugin asked me to trust something.** That is the one-time review for
134
+ the small local hook behind the automatic offer. Decline it and codecall still
135
+ works; you type the command yourself.
223
136
 
224
137
  ## For developers
225
138
 
226
- Want to build, test, or contribute? See [ARCHITECTURE.md](ARCHITECTURE.md)
227
- for the full technical design.
228
-
229
139
  ```bash
230
140
  npm install
231
141
  npm run build
232
142
  npm test
233
- ```
234
-
235
- Validate the plugin before releasing:
236
-
237
- ```bash
238
143
  claude plugin validate ./plugins/codecall
239
144
  ```
240
145
 
241
- Want codecall to show up in Codex's or Claude Code's built-in searchable
242
- plugin list (not just install-by-link)? That needs a separate submission to
243
- each company — see
244
- [Getting listed in curated marketplaces](#getting-listed-in-curated-marketplaces).
245
-
246
- ### Getting listed in curated marketplaces
247
-
248
- **Claude Code** — submit via the
249
- [Plugin Directory Submission Form](https://clau.de/plugin-directory-submission).
250
- The plugin `name` becomes permanent once accepted.
251
-
252
- **Codex** — submit through `platform.openai.com/plugins`, which requires a
253
- verified OpenAI Platform identity and at least five positive and three
254
- negative test cases. Review is asynchronous with no fixed timeline.
146
+ The backend concept map lives in
147
+ `plugins/codecall/skills/codecall/references/backend-map/`, one Markdown file
148
+ per cluster. Edit those files, then run `node scripts/backend-map.mjs` to
149
+ validate them and regenerate `index.md`; `npm test` fails on a stale index, a
150
+ broken prerequisite, a timestamp that is not a real chapter start, or a link
151
+ outside the documentation allowlist.
255
152
 
256
- ### Advanced: using it as a code library
153
+ The canonical skill lives in `plugins/codecall/skills/codecall/`. The
154
+ TypeScript runtime in `src/` is an offline, deterministic test harness for the
155
+ session state machine, not the product; see [ARCHITECTURE.md](ARCHITECTURE.md).
257
156
 
258
- If you're building your own tool on top of codecall, the core runtime is also
259
- a plain TypeScript library (`import { codecall } from "codecall"`). This is a
260
- deterministic, offline demo/test runtime, not the AI-powered product
261
- experience above. See [ARCHITECTURE.md](ARCHITECTURE.md) for the API.
157
+ Listings: Claude Code's [plugin directory submission form](https://clau.de/plugin-directory-submission);
158
+ Codex via `platform.openai.com/plugins`.
262
159
 
263
160
  ## License
264
161
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codecall",
3
- "version": "1.2.3",
3
+ "version": "1.4.0",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "description": "Implementation-grounded adaptive learning skills for Codex and Claude Code.",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codecall",
3
- "version": "1.2.2",
3
+ "version": "1.4.0",
4
4
  "description": "Adaptive implementation-grounded learning for Claude Code.",
5
5
  "author": {
6
6
  "name": "Gaurav",
@@ -9,5 +9,9 @@
9
9
  "homepage": "https://www.npmjs.com/package/codecall",
10
10
  "repository": "https://github.com/GAURAV-1313/codecall",
11
11
  "license": "MIT",
12
- "keywords": ["learning", "developer-education", "implementation"]
12
+ "keywords": [
13
+ "learning",
14
+ "developer-education",
15
+ "implementation"
16
+ ]
13
17
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codecall",
3
- "version": "1.2.2",
3
+ "version": "1.4.0",
4
4
  "description": "Adaptive implementation-grounded learning for Codex.",
5
5
  "author": {
6
6
  "name": "Gaurav",
@@ -9,7 +9,12 @@
9
9
  "homepage": "https://www.npmjs.com/package/codecall",
10
10
  "repository": "https://github.com/GAURAV-1313/codecall",
11
11
  "license": "MIT",
12
- "keywords": ["codex", "claude-code", "learning", "developer-education"],
12
+ "keywords": [
13
+ "codex",
14
+ "claude-code",
15
+ "learning",
16
+ "developer-education"
17
+ ],
13
18
  "skills": "./skills/",
14
19
  "interface": {
15
20
  "displayName": "Codecall",
@@ -17,7 +22,11 @@
17
22
  "longDescription": "A consent-first, adaptive learning skill grounded in completed implementation work.",
18
23
  "developerName": "Gaurav",
19
24
  "category": "Productivity",
20
- "capabilities": ["Interactive"],
21
- "defaultPrompt": ["Teach me the implementation I just completed with Codecall."]
25
+ "capabilities": [
26
+ "Interactive"
27
+ ],
28
+ "defaultPrompt": [
29
+ "Teach me the implementation I just completed with Codecall."
30
+ ]
22
31
  }
23
32
  }
@@ -40,6 +40,11 @@ your starting evidence — you were not part of the conversation that built it.
40
40
  anti-patterns, architecture decisions, and misconceptions distinct. Order by
41
41
  prerequisite. Do not reduce a multi-concept implementation to one
42
42
  vocabulary item.
43
+ 5. Only when the change touches server-side code, read the codecall skill's
44
+ `references/backend-map/index.md` and follow the skill's "Backend concept
45
+ map" rule: at most one map id per concept, only when it truly fits, never
46
+ forced. Order with the ids' `requires`. You may grep `./codecall/*.html`
47
+ for `codecall-concepts` meta tags to find ids missed in earlier sessions.
43
48
 
44
49
  ## Output
45
50
 
@@ -51,7 +56,7 @@ Judgment: recommend | optional | skip
51
56
  Reason: <evidence-backed reason, citing the specific file/decision/signal>
52
57
  Estimated minutes: <N>
53
58
  Plan:
54
- 1. <concept> — <one-line why this matters here> [prerequisite: none|<concept>]
59
+ 1. <concept> — <one-line why this matters here> [prerequisite: none|<concept>] [map: <id>|none]
55
60
  2. ...
56
61
  Evidence limits: <anything the given input didn't establish, if applicable>
57
62
  ```