@pulsarinteractive/geniustasker 0.1.0-beta.1 → 0.1.0-beta.3

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.
package/README.md CHANGED
@@ -1,400 +1,81 @@
1
- # GeniusTasker CLI & MCP · private beta
1
+ # GeniusTasker agent tools
2
2
 
3
- Connect your own AI tools to your projects: read progress, work on tickets,
4
- comment, ask questions and keep a useful handoff. Your account and project
5
- permissions remain the limit. GeniusTasker does not run your agent or bill its
6
- external model tokens.
3
+ Keep project progress, collaborators and your own AI agents in one place.
4
+ This repository contains the public **CLI, local MCP server and agent skills**.
5
+ The GeniusTasker application and service implementation are separate.
6
+ Canonical repository: [PulsarInteractive/geniustasker-agent-tools](https://github.com/PulsarInteractive/geniustasker-agent-tools).
7
+
8
+ [Install](#install-and-connect) · [Codex and Claude](docs/INTEGRATIONS.md) ·
9
+ [CLI reference](docs/CLI.md) · [OpenAI plugin](docs/OPENAI.md) · [Releases](CHANGELOG.md)
7
10
 
8
11
  ## Install and connect
9
12
 
10
- Requires Node.js 22.13 or newer. Install the beta:
13
+ Requires **Node.js 22.13+** and an account admitted to the development beta.
14
+ Installing the client does not enable access to the service.
11
15
 
12
16
  ```sh
13
17
  npm install -g @pulsarinteractive/geniustasker@beta
14
- geniustasker auth login
15
- geniustasker whoami --json
16
- geniustasker projects list --json
18
+ geniustasker auth login --context work
19
+ geniustasker projects list --context work --json
17
20
  ```
18
21
 
19
- Login opens your browser. Sign in to GeniusTasker, choose projects, independent memories and
20
- permissions, then approve the connection. The CLI receives a one-use code with
21
- PKCE; it never asks for your password. The consent page does not load the app tutorial. Decline there or use Ctrl-C to stop.
22
- If the browser cannot open, use the link printed in your terminal.
22
+ A browser opens: sign in, select projects and independent memories, choose
23
+ permissions, then approve. The terminal finishes automatically. No token to copy.
24
+ For Chrome use `--browser chrome`; remote shells can use `--flow device --no-browser`.
25
+ Production agent access is not open in this beta.
23
26
 
24
- **This beta defaults to the development environment.** Your account must be
25
- admitted to the beta; installing the package does not grant access. Production
26
- agent access is closed. Use `--environment production` only when that rollout is
27
- announced. No subscription purchase is performed by the CLI.
27
+ ## Connect an agent
28
28
 
29
- For a remote machine, use `geniustasker auth login --flow device --no-browser`.
30
- For Chrome specifically, use `--browser chrome`. `--context work` creates a
31
- separate local session for an independent terminal; it does not grant extra quota.
32
- The browser offers the supported permissions, with read-only access selected by
33
- default. Write permissions require an explicit choice. To narrow the permissions
34
- offered by the browser, pass `--scope`, for example:
29
+ After logging in with the `work` context:
35
30
 
36
31
  ```sh
37
- geniustasker auth login --context work --scope 'projects:read tasks:read tasks:write comments:write goals:read goals:write'
32
+ codex mcp add geniustasker -- npx -y @pulsarinteractive/geniustasker@0.1.0-beta.3 mcp --context work
38
33
  ```
39
34
 
40
- The browser still requires the human to explicitly grant each permission.
41
- Revoke a session using `geniustasker auth logout --context work` or Account →
42
- Agent connections in the app. Do not put tokens in commands or MCP configuration.
43
-
44
- ## Local MCP
45
-
46
- Authenticate with `geniustasker auth login --context work` outside the MCP process first. Configure a client capable of
47
- launching stdio servers with this entry (adjust environment/context as needed):
48
-
49
- ```json
50
- {
51
- "mcpServers": {
52
- "geniustasker": {
53
- "command": "npx",
54
- "args": ["-y", "@pulsarinteractive/geniustasker@0.1.0-beta.1", "mcp", "--context", "work"]
55
- }
56
- }
57
- }
58
- ```
35
+ Other stdio MCP hosts can use [examples/mcp.json](examples/mcp.json).
36
+ The MCP exposes 16 tools for identity, capabilities, projects, memories, bounded
37
+ reads, profiles and journaled changes. It uses the session you explicitly approved.
38
+ GeniusTasker records work; your agent chooses and executes its own workflow.
59
39
 
60
- No token belongs in that configuration. The server uses the official MCP SDK
61
- and offers `tasker_identity`, `tasker_capabilities`, `tasker_projects` and
62
- `tasker_memories`, `tasker_resources`, plus `tasker_prepare_command`, `tasker_execute_command`,
63
- `tasker_retry_command` and `tasker_inspect_operation`. Profile tools are
64
- `tasker_profiles`, `tasker_create_profile`, `tasker_restrict_profile` and
65
- `tasker_select_profile`. `tasker_question_answers` reads human responses.
66
- `tasker_changes` and `tasker_watch` support resumable changes and bounded waits.
67
- Only MCP JSON-RPC is written to stdout. This is a local
68
- stdio integration, not a hosted MCP service or a marketplace-approved plugin.
69
- The bundled `skills/geniustasker/` folder can be copied into the skill directory
70
- supported by your chosen agent. Specific clients may use a different config
71
- format; their integration guides and release validation remain separate work.
40
+ ## Skills
72
41
 
73
- ## Paging and failures
42
+ - [GeniusTasker](skills/geniustasker/SKILL.md): project work, tickets and useful handoffs.
43
+ - [GeniusTasker Memory](skills/geniustasker-memory/SKILL.md): independent knowledge,
44
+ focused reads, stable blocks and resumable imports.
74
45
 
75
- Commands read one bounded page. Continue with `--after` when `nextAfter` is
76
- non-null, even for an empty filtered project page. Resource continuation also
77
- requires `--epoch` and `--checkpoint` from the first page. A context change
78
- requires restarting the read. `omittedIds` means oversized legacy records were
79
- excluded. Tasks support `--archive active|archived|all`.
46
+ Install the skill folders in your agent's supported skill directory, or use the
47
+ plugin bundle described in [Integrations](docs/INTEGRATIONS.md). npm installation
48
+ alone does not register skills or MCP servers in your agent host.
80
49
 
81
- `--json` gives one versioned result on stdout. Login displays readable progress
82
- by default; with `--json`, its progress uses versioned envelopes on stderr.
83
- Error envelopes also use stderr and do not contain credentials. Exit codes: 2 usage, 3 authentication,
84
- 4 permission, 5 conflict, 6 rate limit, 7 temporary failure, 1 other failure.
85
- Honor `retryAfterSeconds`; there is no hidden retry loop or subscription upgrade.
50
+ ## Plugin readiness
86
51
 
87
- ### Incremental reads and bounded waits
52
+ `plugin.json`, `mcp.json`, `skills/` and the local marketplace catalog form a
53
+ portable **local plugin bundle**. This is not an approved public ChatGPT-directory
54
+ plugin. The hosted HTTPS MCP/OAuth integration remains a separate milestone in
55
+ [OpenAI integration](docs/OPENAI.md).
88
56
 
89
- Complete a resource inventory first. Its final page supplies `changeCursor`;
90
- intermediate pages supply null. Keep this cursor with the same account, scope,
91
- collection and archive view. For example, with the actual returned cursor:
57
+ ## Development
92
58
 
93
59
  ```sh
94
- geniustasker changes list --environment development --context work --scope project:ID --collection tasks --cursor CURSOR --json
95
- geniustasker changes watch --environment development --context work --scope project:ID --collection tasks --cursor CURSOR --wait-seconds 30 --json
60
+ npm ci
61
+ npm run verify
96
62
  ```
97
63
 
98
- Apply all items and removal markers before retaining `nextCursor`. Follow
99
- `hasMore` even if items is empty. These are current projections of changed IDs,
100
- not a historical snapshot; duplicate IDs are possible and record revisions can
101
- be newer than the page checkpoint. Apply newer/equal revisions idempotently and
102
- never replace a newer cached row with an older one. Omissions remain incomplete
103
- evidence. On `restart_read`, replace the collection from a fresh inventory.
104
- Retained-history deletion also demands a full read to protect private audit IDs.
105
-
106
- Watch returns `reason: changes|timeout`, a page (possibly null on timeout), the
107
- number of completed polls and a continuation. It waits at most 60 seconds,
108
- polling no faster than five seconds. Every poll uses the account's normal quota
109
- and live permissions. Ctrl-C or MCP cancellation interrupts it; errors stop it
110
- without blind retries. There is no daemon or automatic background agent. A
111
- Free monthly budget refusal preserves `retryable: false` and its `resetAt` time.
112
-
113
- ## Account rate limits
114
-
115
- Identity and capabilities expose the current server `rateLimits`. All CLI/MCP
116
- contexts and agent profiles on the same account share them. Free allows 30
117
- requests per 60 seconds, Starter 120, Pro 300; within those totals, write requests
118
- are limited to 5, 20 and 60 respectively. These native Cloudflare limits are
119
- approximate and location-local, not billing meters. A command can change several
120
- entities; the rate unit is a request, not an entity or a physical SQL write.
121
-
122
- Starter/Pro have no monthly agent credit/write-request cutoff. Free has 5,000
123
- monthly credits (read request 1, write request 5) and 500 write requests, resetting
124
- at the next UTC month. Every poll/replay consumes the applicable request limits.
125
- On a temporary 429, honor `retryAfterSeconds` (currently a conservative 60 seconds)
126
- before resuming. The CLI reports the error without automatically retrying writes;
127
- keep the same journaled operation ID, issuedAt and content. Do not switch tokens,
128
- profiles or contexts to evade the account limit. A write-only throttle leaves
129
- reads available within their request/Free-credit budget.
130
-
131
- ## Credential storage and recovery
64
+ Tests use synthetic fixtures and local mock servers. CI has no production credentials.
65
+ `npm run check` checks the public file boundary, package contents and plugin schema.
66
+ See [Contributing](CONTRIBUTING.md), [Architecture](docs/ARCHITECTURE.md),
67
+ [Testing](docs/TESTING.md) and [Release process](docs/RELEASING.md).
132
68
 
133
- Credentials live in `~/.geniustasker/<context>.json`, outside repositories.
134
- On POSIX systems the directory is 0700 and files are 0600, with file ownership,
135
- symlink and hard-link checks. This protects against other OS users; it is not a
136
- keychain and does not isolate processes running as you. Windows ACL and native
137
- keychain integration have not been validated in this preview.
69
+ ## Privacy and source boundary
138
70
 
139
- Refresh is serialized across processes and writes are atomic. An uncertainty
140
- marker is saved before rotation: after a lost response, run logout then login
141
- instead of replaying a one-use refresh token. Logout revokes the session family
142
- on the server before removing credentials; on failure it keeps them for retry.
143
- The account's Agents page can revoke a session or whole connection at any time.
144
-
145
- A killed process can leave an empty `<context>.json.lock` directory. Stop every
146
- CLI/MCP process using that context before removing only that empty lock
147
- directory. Never remove a live client's lock. Then run logout/login if renewal
148
- was interrupted. `doctor` exposes no credential values.
149
-
150
- For an isolated local backend, `--origin http://127.0.0.1:PORT --allow-local`
151
- explicitly enables loopback HTTP. Hosted credentials are origin-bound and cannot
152
- be sent there. Redirects on credential-bearing API requests are refused.
153
-
154
- Protocol references: [OAuth device authorization](https://www.rfc-editor.org/rfc/rfc8628),
155
- [OAuth token revocation](https://www.rfc-editor.org/rfc/rfc7009),
156
- [OAuth metadata](https://www.rfc-editor.org/rfc/rfc8414), and the
157
- [official MCP TypeScript SDK](https://github.com/modelcontextprotocol/typescript-sdk).
158
-
159
-
160
- ## Prepare, execute and recover writes
161
-
162
- Request the relevant permissions when connecting, for example:
163
-
164
- ```sh
165
- geniustasker auth login --context work --environment development --scope 'projects:read tasks:read tasks:write comments:write goals:read goals:write' --browser chrome
166
- ```
71
+ No application source, backend, account exports, infrastructure credentials or
72
+ private product documents belong here. Only the agent client and its public
73
+ interface contract are included. Credentials stay in the user's private local
74
+ store; never paste them into an issue. See [Security](SECURITY.md).
167
75
 
168
- The person chooses the effective grant. A project administrator must also enable
169
- agent contributions. Discover capabilities and read the project instructions.
170
- `commands describe --json` describes fields and the draft/request JSON schemas
171
- from the product contract. It does not grant access or prove server activation.
172
-
173
- Save a draft in a private JSON file (replace IDs/epoch with current reads):
174
-
175
- ```json
176
- {
177
- "scope": "project:PROJECT_ID",
178
- "epoch": "EPOCH_FROM_READ",
179
- "id": "NEW_RECORD_UUID",
180
- "expectedRevision": null,
181
- "kind": "task.create",
182
- "data": { "title": "Prepare the next release" }
183
- }
184
- ```
185
-
186
- Then use the same context/environment for the whole workflow:
187
-
188
- ```sh
189
- geniustasker commands prepare --file draft.json --context work --environment development --json
190
- geniustasker commands retry --operation OPERATION_ID --context work --environment development --json
191
- geniustasker commands inspect --operation OPERATION_ID --context work --environment development --json
192
- ```
193
-
194
- Prepare saves a stable UUID/timestamp and sends nothing. Retry executes that
195
- saved operation, whether still prepared or uncertain. Alternatively,
196
- `commands execute --file request.json` accepts a complete request containing
197
- `operationId` and `issuedAt` and journals it before sending. Never regenerate
198
- those values to recover a timeout. Execution errors retain the operation ID.
199
-
200
- The journal lives in `~/.geniustasker/operations/<context>/` with private file
201
- permissions. It contains project text and receipts, never credentials. It is
202
- bound to the original connection, profile, session and API environment. A new
203
- login cannot silently replay an old session's operation. Inspection is local
204
- evidence, not a live permission check. A confirmed retry is labeled
205
- `local_receipt`; a newly obtained receipt is labeled `server`.
206
-
207
- After a revision conflict, reread the affected records and prepare a new edit.
208
- A pending or lost result requires an identical retry. No write is automatically
209
- retried. Journal locks serialize different processes. If a process is killed,
210
- stop all clients before removing that operation's empty `.json.lock` directory.
211
- Keep its JSON request and retry it; do not erase uncertain operations. Journal
212
- retention/cleanup automation remains pending. Logout removes credentials but
213
- retains these records so the outcome can still be inspected.
214
-
215
- Commands cover tasks, dependencies, archive/restore, ticket creation/planning,
216
- comments and goals. `ticket.plan` uses the project ID/root revision and per-task
217
- numeric `expectedVersion`; `ticket.create` requires a UUID record ID. Comments
218
- use a text string and mentions array. An agent can edit/delete only comments
219
- authored by its profile. Server receipts expose changed IDs/revisions, not
220
- record bodies; read them separately if your grant permits it.
221
-
222
- Local validation includes separate processes sharing one write, immutable retry
223
- after lost responses, strict inputs, receipt validation and an official MCP
224
- client communicating through stdio to actual Worker/SQLite domain services.
225
- Hosted owner acceptance and named product integrations remain separate gates.
226
-
227
-
228
- ## Agent profiles and terminal identity
229
-
230
- The initial profile works without configuration. Use independent named contexts
231
- for independent terminals or accounts; a context shared by two processes is one
232
- session, so selecting its profile affects both. Profile names are for attribution,
233
- not extra memberships, API budgets or permission grants.
234
-
235
- ```sh
236
- geniustasker profiles list --context work --environment development --json
237
- geniustasker profiles create --file profile.json --context work --environment development --json
238
- geniustasker profiles select --profile PROFILE_ID --context work --environment development --json
239
- geniustasker whoami --context work --environment development --json
240
- ```
241
-
242
- `profile.json` contains `id` (one UUID chosen once and retained), `name`, and
243
- `grant` with `allResources`, `resourceIds`, `permissions`, following `whoami`'s
244
- grant shape. Use actual project scopes from the API. Creation never switches the
245
- terminal automatically. The new grant must fit both the current profile and the
246
- connection. After a lost creation reply, list profiles and reconcile that UUID;
247
- retrying it cannot allocate a second profile. Do not replace its UUID blindly.
248
-
249
- `profiles restrict --file restriction.json` changes only the current profile.
250
- The file must include its `profileId`, current `expectedRevision`, `name`, and
251
- narrower/equal `grant`. It cannot undo a previous restriction or edit another
252
- profile. After a lost reply, read `whoami` to see the saved revision and grant
253
- before preparing another edit. The explicit profile ID prevents a saved draft
254
- from editing another profile when a process changed the shared context.
255
-
256
- Selection lists only eligible profiles in the same connection, then checks the
257
- source and destination revisions while atomically rotating both credentials.
258
- It never extends the session's absolute lifetime. The previous access token stops
259
- working, so a request in flight cannot silently become the selected profile.
260
- A restricted profile cannot switch back to the broader Default profile. Broader
261
- rights need a human decision in the app or a fresh human-approved connection.
262
- Saved task-operation journals stay bound to their original profile and cannot be
263
- adopted by a different one. Reconcile pending work before selecting another.
264
-
265
- A definite `profile_selection_conflict` or `profile_selection_denied` preserves
266
- the previous usable credentials; read the profile list again. An unknown rotation
267
- outcome requires logout/login, just like an unknown refresh. Credentials never
268
- appear in selection results, CLI output, MCP tool results or package artifacts.
269
-
270
-
271
- ## Ask a human on a ticket
272
-
273
- Request `questions:write` explicitly when connecting; an existing comments grant
274
- alone cannot publish a question. Questions reuse the project's vote feature and
275
- its human access rules. Agent contributions and project votes must both be enabled.
276
- The contract offers fourteen write commands and thirteen MCP tools in this preview.
277
-
278
- Prepare `question.create` with a new retained question UUID, current scope epoch,
279
- null expected revision and this `data` shape (replace IDs and deadline):
280
-
281
- ```json
282
- {
283
- "task": "TICKET_ID",
284
- "question": "Which checks should I run before the release review?",
285
- "description": "I have finished the implementation and need your acceptance criteria.",
286
- "answerKind": "Text",
287
- "eligibleUsers": ["HUMAN_USER_ID"],
288
- "closesAt": "2026-10-05T16:00:00Z"
289
- }
290
- ```
291
-
292
- An explicit audience and future deadline are required for agent questions. `Text`
293
- accepts named answers of up to 2,000 UTF-16 code units and at most 50 recipients.
294
- `YesNo` provides the two canonical options. `Choices` requires 2–12 distinct
295
- options, with `selection: "Single"` or `"Multiple"`; choices can be anonymous.
296
- An agent cannot submit a human ballot. A reply does not expand API permissions
297
- or grant authority for unrelated external actions.
298
-
299
- Use the usual prepare/retry journal for creating and closing questions. Read
300
- `resources list --scope project:ID --collection questions --json` to find their
301
- current revisions, then:
302
-
303
- ```sh
304
- geniustasker questions answers --scope project:ID --question QUESTION_ID --context work --environment development --json
305
- ```
306
-
307
- MCP provides `tasker_question_answers`. Follow `nextAfter` with the original
308
- `epoch` and `checkpoint`; restart after a changed snapshot. Named answers are
309
- paged ten at a time. Anonymous questions expose no respondents or running totals;
310
- after closing they expose only totals. A changing private ballot does not alter
311
- an open anonymous question's public checkpoint.
312
-
313
- `question.close` takes the question's current revision and empty `data`. A
314
- profile can close only questions it created. It cannot answer on behalf of its
315
- owner, impersonate another profile, or use a poll result as new authorization.
316
-
317
-
318
- ## Work updates and handoffs
319
-
320
- Prepare `task.report` through the normal command journal with the current task
321
- revision and `tasks:write`. `phase` is `Working`, `NeedsInformation` or
322
- `NeedsReview`; `summary` is required, `nextSteps` is required for both waiting
323
- phases, and `evidence` is an array of up to eight `{label, url}` HTTPS links.
324
- `mentions` is optional. The ticket must be open, unarchived and agent-enabled.
325
-
326
- The result is one task transition and one attributed, immutable discussion
327
- receipt. Read `workPhase`/`lastWorkReport` on the task and `workReport` on its
328
- comment. Completing/reopening a ticket clears its current phase. A report is
329
- progress information, not approval or proof independently verified by Tasker.
330
- Correct published reports with a new report; never rewrite an older receipt.
331
-
332
-
333
- ## Ask for approval of one precise action
334
-
335
- Connect with `approvals:write` explicitly, alongside the read grants needed to
336
- review the task and its discussion. Discover the commands through capabilities.
337
- Prepare `approval.request` with a retained request UUID, expectedRevision null and:
338
-
339
- ```json
340
- {
341
- "task": "TASK_ID",
342
- "taskRevision": "CURRENT_TASK_REVISION",
343
- "title": "Publish the reviewed preview",
344
- "summary": "Publish build one to the private preview environment.",
345
- "actionJson": "{\"build\":\"one\",\"environment\":\"preview\"}",
346
- "approver": "HUMAN_MEMBER_ID",
347
- "expiresAt": "A_FUTURE_ISO_TIMESTAMP"
348
- }
349
- ```
350
-
351
- The deadline is one minute to seven days ahead. The approver must be a current
352
- human member with ticket editing rights; the requesting account needs those
353
- rights too. Read `comments` for the request's `approval` object and revision.
354
- The designated human reviews the request in the app. No CLI or MCP command can
355
- approve on their behalf. A question answer, comment or work report is not an
356
- approval. Do not store credentials in the action JSON or summary.
357
-
358
- When Approved, prepare `approval.consume` on that comment with its current
359
- expectedRevision and data `{ "requestVersion": "ORIGINAL_REQUEST_REVISION",
360
- "actionJson": "THE_EXACT_REVIEWED_ACTION_JSON" }`. Only its original profile can
361
- consume; the task and access must still match. Reuse prepare/retry/inspect for
362
- network uncertainty. A terminal request cannot authorize a second operation.
363
- `approval.cancel` uses current expectedRevision and `{ "requestVersion": "..." }`
364
- when the request is no longer needed, including stale or expired requests.
365
-
366
- Tasker records authorization and never runs the external action. Use the request
367
- ID as an idempotency key where the external system supports it. After a crash or
368
- an uncertain external result, inspect that system before acting again. Replaying
369
- a successful consumption receipt does not authorize repeating its side effect.
370
-
371
- ## Package boundary
372
-
373
- Only the CLI/MCP source, its generated public command catalog, bundled agent skill
374
- and this README are distributed. Application source, infrastructure configuration,
375
- private product documents, test identities and credentials are excluded. No
376
- installation script runs and no background daemon or telemetry is installed.
377
- The package is distributed for the GeniusTasker beta; no open-source license has
378
- been granted. A public GitHub repository is not required to install it.
379
-
380
- ## Independent memories
381
-
382
- A memory is an account resource (`memory:ID`), not a project attachment. The agent
383
- chooses which project and memory to use independently, within the user's grants.
384
- Use a small index first, then fetch only the page you need:
385
-
386
- ```sh
387
- geniustasker memories list --json
388
- geniustasker resources list --scope memory:ID --collection pageIndex --json
389
- geniustasker resources list --scope memory:ID --collection pages --path brand/identity --json
390
- ```
76
+ ## License
391
77
 
392
- Memory pages contain Markdown blocks with stable IDs, a path, tags and optional
393
- source provenance. Preserve IDs when editing; do not relabel a proposal as a
394
- verified fact. `pages --id ID` also reads one page. A targeted read has no change
395
- cursor; obtain one from a complete collection inventory when watching updates.
396
- Commands `memory.create/update/delete` and `memory.page.create/update/delete`
397
- require `memory:write`. For a new space, choose one UUID for its root ID, scope
398
- suffix and initial epoch, then use the returned epoch/revision for later writes.
399
- All edits use the same local command journal and optimistic revision checks as
400
- project commands. Never copy private source files into this npm package.
78
+ The CLI, MCP server, skills and documentation are available under the
79
+ [MIT license](LICENSE). See [third-party notices](THIRD_PARTY_NOTICES.md) for
80
+ vendor components. The separately hosted GeniusTasker application and backend
81
+ are not part of this repository.
package/SECURITY.md ADDED
@@ -0,0 +1,14 @@
1
+ # Security
2
+
3
+ Report suspected vulnerabilities privately through GitHub's security advisory
4
+ reporting for this repository. Do not put tokens, private project content or
5
+ account exports in public issues. For ordinary bugs, use synthetic reproduction
6
+ steps and redact identifiers that are not needed.
7
+
8
+ The client uses the official service, explicit browser consent, bounded grants
9
+ and private credential files. Revocation is separate from uninstalling npm or a
10
+ plugin. The beta uses development admission; package installation grants nothing.
11
+
12
+ Public changes are checked against a file allowlist and credential/private-path
13
+ patterns, then reviewed before publishing. Automated scans supplement review;
14
+ they cannot guarantee that arbitrary new content is safe to disclose.
@@ -0,0 +1,15 @@
1
+ # Third-party notices
2
+
3
+ ## Agent Plugins JSON schemas
4
+
5
+ `tools/schemas/plugin.schema.json` and `tools/schemas/mcp.schema.json` are
6
+ unmodified Agent Plugins 1.0.0 JSON schemas, used for development validation.
7
+
8
+ - Project: [Agent Plugins specification](https://github.com/agentplugins/agent-plugins-spec)
9
+ - Source: [version 1.0.0 schemas](https://github.com/agentplugins/agent-plugins-spec/tree/main/schemas/1.0.0)
10
+ - License: Apache-2.0, as stated in the [upstream licensing notice](https://github.com/agentplugins/agent-plugins-spec/blob/main/LICENSE.md)
11
+ - Full license: [LICENSES/Apache-2.0.txt](LICENSES/Apache-2.0.txt)
12
+
13
+ These schemas retain their original license. The MIT license for GeniusTasker's
14
+ client does not replace their terms. npm dependencies retain the licenses
15
+ included in their respective packages.
@@ -0,0 +1,104 @@
1
+ # Client architecture
2
+
3
+ The CLI and MCP server share one delegated client. The client communicates with
4
+ the GeniusTasker service; it does not execute an agent's external workflow.
5
+ Projects and account memories are independent resources with explicit grants.
6
+
7
+ ```mermaid
8
+ flowchart LR
9
+ CLI[CLI commands] --> Client[AgentClient]
10
+ Host[Agent host] --> MCP[Local stdio MCP]
11
+ MCP --> Client
12
+ CLI --> Journal[CommandJournal]
13
+ MCP --> Journal
14
+ Journal --> Client
15
+ Client --> Store[Private context store]
16
+ Client --> HTTP[Bounded HTTP transport]
17
+ HTTP --> API[GeniusTasker API]
18
+ ```
19
+
20
+ ## Module responsibilities
21
+
22
+ | Module | Responsibility |
23
+ | --------------------- | --------------------------------------------------------------------------- |
24
+ | `cli.mjs` | Argument validation, context/environment selection, output and exit status |
25
+ | `login.mjs` | Browser PKCE consent, loopback callback validation and optional device flow |
26
+ | `store.mjs` | Private local files, atomic replacement and inter-process locking |
27
+ | `client.mjs` | Origin-bound sessions, serialized renewal, profile selection and reads |
28
+ | `transport.mjs` | Allowed origins/routes, timeouts, size limits and sanitized API failures |
29
+ | `commands.mjs` | Validated command envelopes and durable immutable operation journals |
30
+ | `profiles.mjs` | Bounded profile discovery, creation, restriction and selection |
31
+ | `changes.mjs` | Validated incremental reads and bounded, cancellable waits |
32
+ | `mcp.mjs` | Strict tool schemas and protocol-safe responses over stdio |
33
+ | `errors.mjs` | Stable errors, safe serialization and CLI exit codes |
34
+ | `command-catalog.mjs` | Generated public interface definitions and limits |
35
+
36
+ ## Authentication and renewal
37
+
38
+ 1. The user starts `auth login` outside the MCP process. Browser consent selects
39
+ resources and permissions; the CLI receives a one-use code through a validated
40
+ loopback callback and exchanges it using PKCE.
41
+ 2. Credentials are validated against the expected origin and identity before being
42
+ written. Local storage uses a dedicated context and restrictive permissions.
43
+ 3. Before renewal, the client acquires the context lock and persists a
44
+ `refreshPending` marker. Concurrent processes cannot renew the same credential
45
+ family simultaneously.
46
+ 4. A successful, validated response replaces both tokens atomically. An uncertain
47
+ response leaves the marker intact and requires reconnecting. It must not replay
48
+ a possibly consumed refresh token.
49
+ 5. Logout revokes the server session before deleting local credentials. A failed
50
+ revoke retains the local state for recovery.
51
+
52
+ Separate contexts give terminals independent consented sessions. Sharing a context
53
+ shares its identity and locks. Profile selection can narrow access; it cannot
54
+ restore a broader grant or extend the server's absolute session lifetime.
55
+
56
+ ## Writes and recovery
57
+
58
+ A domain command carries its scope, epoch, current revision, operation ID and
59
+ issue time. `prepare` validates and saves the complete request locally without
60
+ performing a domain write. The journal binds it to an origin, connection, profile
61
+ and session.
62
+
63
+ ```mermaid
64
+ stateDiagram-v2
65
+ [*] --> prepared: save validated draft
66
+ prepared --> uncertain: persist before sending
67
+ uncertain --> confirmed: validate and save receipt
68
+ uncertain --> uncertain: explicit identical retry
69
+ confirmed --> confirmed: return saved receipt
70
+ ```
71
+
72
+ A timeout or malformed receipt does not establish whether the server committed.
73
+ The operation stays uncertain. The caller can retry the same saved request; it
74
+ cannot replace the body under the same ID or replay it after an identity change.
75
+ A conflict requires a fresh read and a new operation. The journal never stores
76
+ authentication tokens.
77
+
78
+ Profile changes use a separate lifecycle: creation keeps the caller's UUID,
79
+ restriction uses a current revision, and selection rotates credentials while
80
+ holding the context lock. They are not domain-journal operations.
81
+
82
+ ## Reads and change cursors
83
+
84
+ Resource reads are bounded and permission-filtered. Callers preserve inventory
85
+ epoch/checkpoint fields while paging and follow continuation even when a page is
86
+ empty. A cursor does not grant access. Change pages validate scope, collection,
87
+ revision and shape before advancing saved state.
88
+
89
+ `watch` performs one bounded wait. It honors the server's polling interval and
90
+ cancellation; quota errors, expired history and revocation stop the wait. There is
91
+ no background subscription daemon or automatic monthly-limit retry loop.
92
+
93
+ ## Transport and extension points
94
+
95
+ Requests are confined to delegated API routes and approved origins. Redirects
96
+ are refused. Requests and responses are size-bounded; raw network exceptions
97
+ never become user-facing diagnostic text. CLI stdout and MCP stdout stay free of
98
+ logging and browser-authentication prompts.
99
+
100
+ Add a public capability by updating its generated contract, boundary validation,
101
+ client operation, CLI/MCP adapter, failure tests and user documentation together.
102
+ Prefer existing transport and storage primitives. A future remote MCP adapter is
103
+ a separate integration described in [OpenAI integration](OPENAI.md); the current
104
+ local plugin manifest must not imply that endpoint already exists.