diff --git a/.greptile/config.json b/.greptile/config.json deleted file mode 100644 index 35ee8ecd..00000000 --- a/.greptile/config.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "strictness": 2, - "commentTypes": ["logic", "syntax", "style"], - "triggerOnUpdates": true, - "includeBranches": ["main"], - "ignoreKeywords": "WIP\nDO NOT REVIEW", - "ignorePatterns": "node_modules/**\ndist/**\nbuild/**\n**/*.min.js\npnpm-lock.yaml\nflake.lock\n**/*.snap\nreports/**\n**/*.webp\n**/*.png\n**/*.gif", - "instructions": "TypeScript pnpm monorepo for pythinker-code, a provider-agnostic AI coding agent. The published user-facing package is the CLI (@pymodel/pythinker-code); packages/node-sdk is the public TypeScript SDK; packages/agent-core, kosong, kaos, oauth, and telemetry are internal engine packages. apps/* are the CLI/TUI, web UI, and dashboard. The root AGENTS.md is the authoritative contributor guide; nearest sub-directory AGENTS.md files add local rules.", - "rules": [ - { - "id": "no-type-weakening", - "rule": "Do not weaken types to silence errors: no `any`, unconstrained `unknown`, `@ts-ignore`, or type assertions added only to make a type error go away.", - "scope": ["packages/**", "apps/**"], - "severity": "high" - }, - { - "id": "flake-workspace-sync", - "rule": "When a workspace package is added or removed in pnpm-workspace.yaml, flake.nix workspacePaths and workspaceNames must be updated in the same PR. A missing path silently drops files from the Nix build.", - "severity": "high" - }, - { - "id": "tests-can-fail", - "rule": "Tests must be able to fail. Flag vacuous assertions: empty-set matches, missing awaits on async expectations, and mocked units asserting on the mock itself.", - "scope": ["**/*.test.ts", "**/*.test.tsx"], - "severity": "medium" - }, - { - "id": "tui-reactivity", - "rule": "Solid signals must not be destructured, rendering must stay allocation-light, and no blocking I/O on the render path.", - "scope": ["apps/pythinker-code/src/tui/**"], - "severity": "high" - }, - { - "id": "changeset-required", - "rule": "Every PR that affects release artifacts (code, behavior, or public API) must include a changeset; only docs-only, test-only, or CI-only PRs may skip one. Default to minor or patch; a major bump requires explicit maintainer confirmation.", - "severity": "medium" - } - ] -} diff --git a/.greptile/files.json b/.greptile/files.json deleted file mode 100644 index 28e6b649..00000000 --- a/.greptile/files.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "files": [ - { - "path": "AGENTS.md", - "description": "Repository-wide contributor guide: product identity, project map, coding rules, and PR workflow" - }, - { - "path": "apps/pythinker-code/AGENTS.md", - "description": "CLI / terminal UI app rules", - "scope": ["apps/pythinker-code/**"] - }, - { - "path": "apps/pythinker-web/AGENTS.md", - "description": "Browser UI (Vue 3) rules", - "scope": ["apps/pythinker-web/**"] - }, - { - "path": "packages/agent-core/src/services/AGENTS.md", - "description": "Service layer rules: naming, layout, and registration conventions", - "scope": ["packages/agent-core/src/services/**"] - }, - { - "path": "packages/server/AGENTS.md", - "description": "Server package rules (REST + WS /api/v1)", - "scope": ["packages/server/**"] - }, - { - "path": "packages/server-e2e/AGENTS.md", - "description": "E2E test suite rules", - "scope": ["packages/server-e2e/**"] - }, - { - "path": "docs/AGENTS.md", - "description": "Documentation rules", - "scope": ["docs/**"] - } - ] -} diff --git a/.greptile/rules.md b/.greptile/rules.md deleted file mode 100644 index 5f79d882..00000000 --- a/.greptile/rules.md +++ /dev/null @@ -1,23 +0,0 @@ -# Review Rules - -## TypeScript conventions - -- `user?: User`, never `user?: User | undefined`. -- Pass `undefined` directly for optional props — no conditional spread. -- Single-param internal methods stay single-param — no options-object wrapping. -- Non-root `index.ts` files: prefer `export * from './module'`. -- Prefer `import ... from '#/...'` over deep relative paths (equivalent to `@/...`). - -## Architecture boundaries - -- `apps/pythinker-code` and `apps/pythinker-web` must not depend on `packages/agent-core`. They consume the SDK (`@pymodel/pythinker-code-sdk`) or the server REST/WS API. -- The `Agent` class in `packages/agent-core` stays standalone: no mandatory `Session` or `agentId`; optional `sessionId` is a provider hint only. -- `packages/acp-adapter` pins `@agentclientprotocol/sdk` to `^0.23.0` — flag any bump to 0.24+ (it broke the session-model API). -- Experimental features are gated behind flags in `packages/agent-core/src/flags/registry.ts`, not shipped unguarded. - -## Hygiene - -- English-only code, comments, and identifiers. Unicode tests use ASCII/Latin fixtures (e.g. `café`). -- No backward-compatibility shims; implement the current requirement directly. -- Prefer adding tests to existing test files over creating new ones. -- Internal identifiers must not appear in public text or test data — use neutral placeholders.