Skip to content

Update skills for more accuracy + to satisfy audit#1377

Merged
atharvadeosthale merged 2 commits intomasterfrom
tweak-skills
Mar 9, 2026
Merged

Update skills for more accuracy + to satisfy audit#1377
atharvadeosthale merged 2 commits intomasterfrom
tweak-skills

Conversation

@atharvadeosthale
Copy link
Member

@atharvadeosthale atharvadeosthale commented Mar 9, 2026

Summary by CodeRabbit

  • Documentation

    • Updated CLI and docs to use TablesDB naming and standardized "column" terminology across guides and examples.
    • Updated real-time subscription examples and available-channel references to the new tablesdb namespace (Dart, Kotlin, TypeScript).
  • Breaking Changes

    • Client examples and Swift SDK usage moved to a Channel-based, async subscription API (subscribe now uses Channel builders and async/await patterns).

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 9, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 8cbd910c-ba26-410e-91d7-9645f512a465

📥 Commits

Reviewing files that changed from the base of the PR and between d0c835d and 2d31dde.

📒 Files selected for processing (4)
  • templates/agent-skills/dart.md.twig
  • templates/agent-skills/kotlin.md.twig
  • templates/agent-skills/swift.md.twig
  • templates/agent-skills/typescript.md.twig
🚧 Files skipped from review as they are similar to previous changes (1)
  • templates/agent-skills/kotlin.md.twig

📝 Walkthrough

Walkthrough

Documentation templates updated to migrate CLI commands and real-time channel namespace references from the databases namespace to tablesdb, and to rename legacy "attribute" terminology to "column" across CLI and SDK examples; Swift realtime subscribe API examples updated to use Channel helpers and async usage.

Changes

Cohort / File(s) Summary
CLI Documentation
templates/agent-skills/cli.md.twig
Replaced appwrite databases ... CLI commands with appwrite tables-db ... equivalents across table/row/column/index commands; renamed "attribute" to "column" command names and updated headings and usage notes to reference TablesDB and Non-Interactive Mode where applicable.
Dart SDK Real-time Examples
templates/agent-skills/dart.md.twig
Switched realtime channel examples from databases.[DATABASE_ID].tables.[TABLE_ID].rows to tablesdb('[DATABASE_ID]').table('[TABLE_ID]').row() and updated emitted event names and channel description entries to use the tablesdb.* namespace; multi-channel examples updated (Bucket -> Channel.bucket).
Kotlin SDK Real-time Examples
templates/agent-skills/kotlin.md.twig
Replaced channel literals with Channel.tablesdb("[DATABASE_ID]").table("[TABLE_ID]").row() patterns; updated imports, multi-channel examples, and event payload examples to tablesdb.* namespace; adjusted available channels table.
Swift SDK Real-time API & Examples
templates/agent-skills/swift.md.twig
Updated examples to use Channel helpers and async/throwing Realtime.subscribe usage (channels now Channel values); public subscribe signature shown as changing from string array to [Channel] and examples updated to tablesdb.* channel names and try await usage.
TypeScript SDK Real-time Examples
templates/agent-skills/typescript.md.twig
Moved from string-based topic subscriptions to Channel builders (e.g., Channel.tablesdb(...).table(...).row()), updated imports and realtime.subscribe usage to accept Channel builders, adjusted multi-channel arrays and subscription.close() unsubscription; channel names and available channels table changed to tablesdb.*.

Sequence Diagram(s)

(omitted)

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

A rabbit hops where namespaces shift and play,
From databases to tablesdb it ran today.
Columns renamed, channels dressed anew,
I nibbled docs and cheered—oh what a view! 🐇✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'Update skills for more accuracy + to satisfy audit' is vague and generic. It uses non-descriptive terms that don't convey the specific technical changes being made (TablesDB migration, channel namespace updates, API signature changes across multiple SDK templates). Consider a more specific title that highlights the primary change, such as 'Migrate real-time subscriptions and CLI commands to TablesDB API' or 'Update SDK templates for TablesDB namespace and Channel-based subscriptions'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch tweak-skills

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@templates/agent-skills/cli.md.twig`:
- Around line 273-275: The doc lists non-existent CLI commands (`appwrite
tables-db list-column-indexes`, `create-column-index`, `delete-column-index`) —
remove these three rows from the CLI documentation in
templates/agent-skills/cli.md.twig unless you intend to expose them; if you do
intend to expose them, implement CLI handlers that map to the service methods
(`listIndexes`, `createIndex`, `deleteIndex`) and wire them into the CLI
dispatch so the commands actually exist before documenting them.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 34a1e5d0-2581-4800-a283-d50435ec5ea9

📥 Commits

Reviewing files that changed from the base of the PR and between 1d39f64 and d0c835d.

📒 Files selected for processing (5)
  • templates/agent-skills/cli.md.twig
  • templates/agent-skills/dart.md.twig
  • templates/agent-skills/kotlin.md.twig
  • templates/agent-skills/swift.md.twig
  • templates/agent-skills/typescript.md.twig

Comment on lines +273 to +275
| `appwrite tables-db list-column-indexes --database-id <ID> --table-id <ID>` | List indexes |
| `appwrite tables-db create-column-index --database-id <ID> --table-id <ID>` | Create index |
| `appwrite tables-db delete-column-index --database-id <ID> --table-id <ID> --key <KEY>` | Delete index |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Template mentions:\n'
rg -n -C2 'appwrite tables-db (list-column-indexes|create-column-index|delete-column-index|list-indexes|create-index|delete-index|get-index)' templates

printf '\nGenerator / spec symbols:\n'
rg -n -C2 '\b(listIndexes|getIndex|createIndex|deleteIndex|listColumnIndexes|createColumnIndex|deleteColumnIndex)\b'

Repository: appwrite/sdk-generator

Length of output: 2678


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Search for tables-db command definitions:\n'
rg -n 'tables-db|tablesDb|tables-db' --type ts --type js | grep -i 'list.*index\|create.*index\|delete.*index' | head -20

printf '\nSearch for column-index command definitions:\n'
rg -n 'column-index|columnIndex|column-indexes|columnIndexes' --type ts --type js | head -20

printf '\nSearch for tables-db in command files:\n'
fd -e ts -e js | xargs grep -l 'tables-db' 2>/dev/null | head -10

Repository: appwrite/sdk-generator

Length of output: 107


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Look for spec or schema files:\n'
find . -type f \( -name '*.json' -o -name '*.yaml' -o -name '*.yml' \) | grep -E '(spec|schema|command)' | head -20

printf '\nSearch for any mention of column-index in the entire repo:\n'
rg -n 'column.index|columnIndex' --type-list | head -20

printf '\nLook in templates/cli for how commands are generated:\n'
find templates/cli -type f -name '*.ts' -o -name '*.js' | head -10

printf '\nCheck for existing tables/database commands in the codebase:\n'
rg -n 'tables-db|database.*index' templates/cli --type ts --type js | head -20

Repository: appwrite/sdk-generator

Length of output: 591


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Check spec.json for tables-db service definitions:\n'
jq '.services[] | select(.name | contains("tables")) | {name, methods: [.methods[] | select(.name | contains("Index")) | {name, sdk: .sdk}]}' tests/resources/spec.json 2>/dev/null | head -50

printf '\nIf above is empty, search raw for index-related methods:\n'
rg -n 'listColumnIndexes|list.*Index|createColumnIndex|create.*Index|deleteColumnIndex|delete.*Index' tests/resources/spec.json

Repository: appwrite/sdk-generator

Length of output: 116


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'File size and first lines of spec.json:\n'
wc -l tests/resources/spec.json
head -100 tests/resources/spec.json

printf '\n\nSearch for tables in spec.json:\n'
grep -n '"tables"' tests/resources/spec.json | head -10

printf '\nSearch for columnIndex or column-index:\n'
grep -n -i 'columnindex\|column.index' tests/resources/spec.json

Repository: appwrite/sdk-generator

Length of output: 2820


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Look for command generation or mapping in templates/cli:\n'
find templates/cli -type f | head -20

printf '\nSearch for how method names become command names (camelCase to kebab-case):\n'
rg -n 'listIndexes|createIndex|deleteIndex' templates/cli --type ts --type js -A 2 | head -40

printf '\nLook for "column" and "index" together in templates:\n'
rg -n 'column.*index|index.*column' templates/cli --type ts --type js -i | head -20

Repository: appwrite/sdk-generator

Length of output: 3898


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Search for CLI command generation or spec-to-command mapping:\n'
rg -n 'tables.db|tablesDb|tables-db' --type ts --type js templates/cli | head -20

printf '\nSearch for where commands are registered/generated:\n'
fd -e ts -path '*/templates/cli/*' | xargs grep -l 'command.*register\|addCommand\|register.*command' 2>/dev/null | head -5

printf '\nLook for swagger/spec parsing to command generation:\n'
rg -n 'listIndexes\|createIndex\|deleteIndex' templates/cli/cli.ts.twig -A 3 -B 3 2>/dev/null | head -30

Repository: appwrite/sdk-generator

Length of output: 526


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Read parser.ts around tables-db definition:\n'
sed -n '280,350p' templates/cli/lib/parser.ts

printf '\nSearch for list-column-indexes or similar index commands in parser:\n'
rg -n 'list-column|create-column|delete-column|list-index|create-index|delete-index' templates/cli/lib/parser.ts -A 2 | head -50

Repository: appwrite/sdk-generator

Length of output: 3201


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Search for ALL tables-db command definitions:\n'
rg -n '"tables-db' templates/cli --type ts --type js -A 5 -B 2 | head -60

printf '\nSearch for any index-related commands in the CLI:\n'
rg -n 'index' templates/cli/lib/parser.ts -A 1 -B 1

printf '\nCheck if tables-db has any sub-commands defined:\n'
rg -n 'databases\.|tables-db' templates/cli/cli.ts.twig -A 2 -B 2 2>/dev/null || echo "Not in cli.ts.twig"

Repository: appwrite/sdk-generator

Length of output: 1455


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Look for how databases service commands are generated:\n'
rg -n '"databases' templates/cli/lib/parser.ts -A 10 -B 2

printf '\nSearch for actual command definitions in CLI that show sub-commands:\n'
rg -n 'command\s*=' templates/cli/lib/commands -l | head -10

printf '\nCheck if cli.md.twig is generated or manually maintained:\n'
head -20 templates/agent-skills/cli.md.twig

Repository: appwrite/sdk-generator

Length of output: 120


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Read the cli.md.twig file around the tables-db section:\n'
sed -n '260,290p' templates/agent-skills/cli.md.twig

printf '\n\nCheck if this template is auto-generated or manually edited:\n'
head -30 templates/agent-skills/cli.md.twig

printf '\n\nLook at database commands for comparison:\n'
sed -n '200,260p' templates/agent-skills/cli.md.twig | tail -50

Repository: appwrite/sdk-generator

Length of output: 4044


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf 'Search for any appwrite SDK or spec that documents these commands:\n'
rg -n 'list.*[Ii]ndex|create.*[Ii]ndex|delete.*[Ii]ndex' --type ts --type js --type json | grep -E '(tables|index)' -i | head -30

printf '\nSearch for the actual list of tables-db commands in a spec or command list:\n'
rg -n 'appwrite tables-db' templates/ --type ts --type js --type json | head -20

printf '\nLook for command name generation patterns:\n'
rg -n 'list-|create-|delete-' templates/cli/lib/commands -l | head -5

Repository: appwrite/sdk-generator

Length of output: 1550


These tables-db index commands do not appear to be exposed as direct CLI commands and should not be documented.

The documented commands (list-column-indexes, create-column-index, delete-column-index) do not exist as user-facing CLI commands. The corresponding service methods (listIndexes, createIndex, deleteIndex) are used only internally during table configuration workflows in push and init operations, not as standalone commands users can run. Either remove these rows from the table or verify whether these commands should actually be exposed to users before documenting them.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@templates/agent-skills/cli.md.twig` around lines 273 - 275, The doc lists
non-existent CLI commands (`appwrite tables-db list-column-indexes`,
`create-column-index`, `delete-column-index`) — remove these three rows from the
CLI documentation in templates/agent-skills/cli.md.twig unless you intend to
expose them; if you do intend to expose them, implement CLI handlers that map to
the service methods (`listIndexes`, `createIndex`, `deleteIndex`) and wire them
into the CLI dispatch so the commands actually exist before documenting them.

@atharvadeosthale atharvadeosthale merged commit f80e302 into master Mar 9, 2026
55 checks passed
@atharvadeosthale atharvadeosthale deleted the tweak-skills branch March 9, 2026 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants