@mmmbuto/qwen-code-termux 0.13.1-termux → 0.14.1-termux

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 (79) hide show
  1. package/README.md +66 -157
  2. package/bundled/loop/SKILL.md +61 -0
  3. package/bundled/qc-helper/SKILL.md +151 -0
  4. package/bundled/qc-helper/docs/_meta.ts +30 -0
  5. package/bundled/qc-helper/docs/common-workflow.md +571 -0
  6. package/bundled/qc-helper/docs/configuration/_meta.ts +10 -0
  7. package/bundled/qc-helper/docs/configuration/auth.md +366 -0
  8. package/bundled/qc-helper/docs/configuration/memory.md +0 -0
  9. package/bundled/qc-helper/docs/configuration/model-providers.md +542 -0
  10. package/bundled/qc-helper/docs/configuration/qwen-ignore.md +55 -0
  11. package/bundled/qc-helper/docs/configuration/settings.md +664 -0
  12. package/bundled/qc-helper/docs/configuration/themes.md +160 -0
  13. package/bundled/qc-helper/docs/configuration/trusted-folders.md +61 -0
  14. package/bundled/qc-helper/docs/extension/_meta.ts +9 -0
  15. package/bundled/qc-helper/docs/extension/extension-releasing.md +204 -0
  16. package/bundled/qc-helper/docs/extension/getting-started-extensions.md +299 -0
  17. package/bundled/qc-helper/docs/extension/introduction.md +338 -0
  18. package/bundled/qc-helper/docs/features/_meta.ts +20 -0
  19. package/bundled/qc-helper/docs/features/approval-mode.md +263 -0
  20. package/bundled/qc-helper/docs/features/arena.md +218 -0
  21. package/bundled/qc-helper/docs/features/channels/_meta.ts +7 -0
  22. package/bundled/qc-helper/docs/features/channels/dingtalk.md +134 -0
  23. package/bundled/qc-helper/docs/features/channels/overview.md +336 -0
  24. package/bundled/qc-helper/docs/features/channels/plugins.md +87 -0
  25. package/bundled/qc-helper/docs/features/channels/telegram.md +120 -0
  26. package/bundled/qc-helper/docs/features/channels/weixin.md +106 -0
  27. package/bundled/qc-helper/docs/features/checkpointing.md +77 -0
  28. package/bundled/qc-helper/docs/features/commands.md +381 -0
  29. package/bundled/qc-helper/docs/features/followup-suggestions.md +109 -0
  30. package/bundled/qc-helper/docs/features/headless.md +318 -0
  31. package/bundled/qc-helper/docs/features/hooks.md +720 -0
  32. package/bundled/qc-helper/docs/features/language.md +139 -0
  33. package/bundled/qc-helper/docs/features/lsp.md +417 -0
  34. package/bundled/qc-helper/docs/features/mcp.md +281 -0
  35. package/bundled/qc-helper/docs/features/sandbox.md +241 -0
  36. package/bundled/qc-helper/docs/features/scheduled-tasks.md +139 -0
  37. package/bundled/qc-helper/docs/features/skills.md +289 -0
  38. package/bundled/qc-helper/docs/features/sub-agents.md +515 -0
  39. package/bundled/qc-helper/docs/features/token-caching.md +29 -0
  40. package/bundled/qc-helper/docs/ide-integration/_meta.ts +4 -0
  41. package/bundled/qc-helper/docs/ide-integration/ide-companion-spec.md +182 -0
  42. package/bundled/qc-helper/docs/ide-integration/ide-integration.md +144 -0
  43. package/bundled/qc-helper/docs/integration-github-action.md +241 -0
  44. package/bundled/qc-helper/docs/integration-jetbrains.md +81 -0
  45. package/bundled/qc-helper/docs/integration-vscode.md +39 -0
  46. package/bundled/qc-helper/docs/integration-zed.md +72 -0
  47. package/bundled/qc-helper/docs/overview.md +65 -0
  48. package/bundled/qc-helper/docs/quickstart.md +273 -0
  49. package/bundled/qc-helper/docs/reference/_meta.ts +3 -0
  50. package/bundled/qc-helper/docs/reference/keyboard-shortcuts.md +72 -0
  51. package/bundled/qc-helper/docs/support/Uninstall.md +42 -0
  52. package/bundled/qc-helper/docs/support/_meta.ts +6 -0
  53. package/bundled/qc-helper/docs/support/tos-privacy.md +112 -0
  54. package/bundled/qc-helper/docs/support/troubleshooting.md +123 -0
  55. package/bundled/review/SKILL.md +261 -0
  56. package/{dist/cli.js → cli.js} +91028 -57660
  57. package/locales/de.js +1976 -0
  58. package/locales/en.js +2016 -0
  59. package/locales/ja.js +1467 -0
  60. package/locales/pt.js +1966 -0
  61. package/locales/ru.js +1973 -0
  62. package/locales/zh.js +1820 -0
  63. package/package.json +33 -119
  64. package/scripts/postinstall.cjs +12 -0
  65. package/dist/bundled/review/SKILL.md +0 -123
  66. /package/{dist/sandbox-macos-permissive-closed.sb → sandbox-macos-permissive-closed.sb} +0 -0
  67. /package/{dist/sandbox-macos-permissive-open.sb → sandbox-macos-permissive-open.sb} +0 -0
  68. /package/{dist/sandbox-macos-permissive-proxied.sb → sandbox-macos-permissive-proxied.sb} +0 -0
  69. /package/{dist/sandbox-macos-restrictive-closed.sb → sandbox-macos-restrictive-closed.sb} +0 -0
  70. /package/{dist/sandbox-macos-restrictive-open.sb → sandbox-macos-restrictive-open.sb} +0 -0
  71. /package/{dist/sandbox-macos-restrictive-proxied.sb → sandbox-macos-restrictive-proxied.sb} +0 -0
  72. /package/{dist/vendor → vendor}/ripgrep/COPYING +0 -0
  73. /package/{dist/vendor → vendor}/ripgrep/arm64-darwin/rg +0 -0
  74. /package/{dist/vendor → vendor}/ripgrep/arm64-linux/rg +0 -0
  75. /package/{dist/vendor → vendor}/ripgrep/x64-darwin/rg +0 -0
  76. /package/{dist/vendor → vendor}/ripgrep/x64-linux/rg +0 -0
  77. /package/{dist/vendor → vendor}/ripgrep/x64-win32/rg.exe +0 -0
  78. /package/{dist/vendor → vendor}/tree-sitter/tree-sitter-bash.wasm +0 -0
  79. /package/{dist/vendor → vendor}/tree-sitter/tree-sitter.wasm +0 -0
@@ -0,0 +1,515 @@
1
+ # Subagents
2
+
3
+ Subagents are specialized AI assistants that handle specific types of tasks within Qwen Code. They allow you to delegate focused work to AI agents that are configured with task-specific prompts, tools, and behaviors.
4
+
5
+ ## What are Subagents?
6
+
7
+ Subagents are independent AI assistants that:
8
+
9
+ - **Specialize in specific tasks** - Each Subagent is configured with a focused system prompt for particular types of work
10
+ - **Have separate context** - They maintain their own conversation history, separate from your main chat
11
+ - **Use controlled tools** - You can configure which tools each Subagent has access to
12
+ - **Work autonomously** - Once given a task, they work independently until completion or failure
13
+ - **Provide detailed feedback** - You can see their progress, tool usage, and execution statistics in real-time
14
+
15
+ ## Key Benefits
16
+
17
+ - **Task Specialization**: Create agents optimized for specific workflows (testing, documentation, refactoring, etc.)
18
+ - **Context Isolation**: Keep specialized work separate from your main conversation
19
+ - **Reusability**: Save and reuse agent configurations across projects and sessions
20
+ - **Controlled Access**: Limit which tools each agent can use for security and focus
21
+ - **Progress Visibility**: Monitor agent execution with real-time progress updates
22
+
23
+ ## How Subagents Work
24
+
25
+ 1. **Configuration**: You create Subagents configurations that define their behavior, tools, and system prompts
26
+ 2. **Delegation**: The main AI can automatically delegate tasks to appropriate Subagents
27
+ 3. **Execution**: Subagents work independently, using their configured tools to complete tasks
28
+ 4. **Results**: They return results and execution summaries back to the main conversation
29
+
30
+ ## Getting Started
31
+
32
+ ### Quick Start
33
+
34
+ 1. **Create your first Subagent**:
35
+
36
+ `/agents create`
37
+
38
+ Follow the guided wizard to create a specialized agent.
39
+
40
+ 2. **Manage existing agents**:
41
+
42
+ `/agents manage`
43
+
44
+ View and manage your configured Subagents.
45
+
46
+ 3. **Use Subagents automatically**: Simply ask the main AI to perform tasks that match your Subagents' specializations. The AI will automatically delegate appropriate work.
47
+
48
+ ### Example Usage
49
+
50
+ ```
51
+ User: "Please write comprehensive tests for the authentication module"
52
+ AI: I'll delegate this to your testing specialist Subagents.
53
+ [Delegates to "testing-expert" Subagents]
54
+ [Shows real-time progress of test creation]
55
+ [Returns with completed test files and execution summary]`
56
+ ```
57
+
58
+ ## Management
59
+
60
+ ### CLI Commands
61
+
62
+ Subagents are managed through the `/agents` slash command and its subcommands:
63
+
64
+ **Usage:**:`/agents create`。Creates a new Subagent through a guided step wizard.
65
+
66
+ **Usage:**:`/agents manage`。Opens an interactive management dialog for viewing and managing existing Subagents.
67
+
68
+ ### Storage Locations
69
+
70
+ Subagents are stored as Markdown files in multiple locations:
71
+
72
+ - **Project-level**: `.qwen/agents/` (highest precedence)
73
+ - **User-level**: `~/.qwen/agents/` (fallback)
74
+ - **Extension-level**: Provided by installed extensions
75
+
76
+ This allows you to have project-specific agents, personal agents that work across all projects, and extension-provided agents that add specialized capabilities.
77
+
78
+ ### Extension Subagents
79
+
80
+ Extensions can provide custom subagents that become available when the extension is enabled. These agents are stored in the extension's `agents/` directory and follow the same format as personal and project agents.
81
+
82
+ Extension subagents:
83
+
84
+ - Are automatically discovered when the extension is enabled
85
+ - Appear in the `/agents manage` dialog under "Extension Agents" section
86
+ - Cannot be edited directly (edit the extension source instead)
87
+ - Follow the same configuration format as user-defined agents
88
+
89
+ To see which extensions provide subagents, check the extension's `qwen-extension.json` file for an `agents` field.
90
+
91
+ ### File Format
92
+
93
+ Subagents are configured using Markdown files with YAML frontmatter. This format is human-readable and easy to edit with any text editor.
94
+
95
+ #### Basic Structure
96
+
97
+ ```
98
+ ---
99
+ name: agent-name
100
+ description: Brief description of when and how to use this agent
101
+ model: inherit # Optional: inherit or model-id
102
+ tools:
103
+ - tool1
104
+ - tool2
105
+ - tool3 # Optional
106
+ ---
107
+
108
+ System prompt content goes here.
109
+ Multiple paragraphs are supported.
110
+ ```
111
+
112
+ #### Model Selection
113
+
114
+ Use the optional `model` frontmatter field to control which model a subagent uses:
115
+
116
+ - `inherit`: Use the same model as the main conversation
117
+ - Omit the field: Same as `inherit`
118
+ - `glm-5`: Use that model ID with the main conversation's auth type
119
+ - `openai:gpt-4o`: Use a different provider (resolves credentials from env vars)
120
+
121
+ #### Example Usage
122
+
123
+ ```
124
+ ---
125
+ name: project-documenter
126
+ description: Creates project documentation and README files
127
+ ---
128
+
129
+ You are a documentation specialist.
130
+
131
+ Focus on creating clear, comprehensive documentation that helps both
132
+ new contributors and end users understand the project.
133
+ ```
134
+
135
+ ## Using Subagents Effectively
136
+
137
+ ### Automatic Delegation
138
+
139
+ Qwen Code proactively delegates tasks based on:
140
+
141
+ - The task description in your request
142
+ - The description field in Subagents configurations
143
+ - Current context and available tools
144
+
145
+ To encourage more proactive Subagents use, include phrases like "use PROACTIVELY" or "MUST BE USED" in your description field.
146
+
147
+ ### Explicit Invocation
148
+
149
+ Request a specific Subagent by mentioning it in your command:
150
+
151
+ ```
152
+ Let the testing-expert Subagents create unit tests for the payment module
153
+ Have the documentation-writer Subagents update the API reference
154
+ Get the react-specialist Subagents to optimize this component's performance
155
+ ```
156
+
157
+ ## Examples
158
+
159
+ ### Development Workflow Agents
160
+
161
+ #### Testing Specialist
162
+
163
+ Perfect for comprehensive test creation and test-driven development.
164
+
165
+ ```
166
+ ---
167
+ name: testing-expert
168
+ description: Writes comprehensive unit tests, integration tests, and handles test automation with best practices
169
+ tools:
170
+ - read_file
171
+ - write_file
172
+ - read_many_files
173
+ - run_shell_command
174
+ ---
175
+
176
+ You are a testing specialist focused on creating high-quality, maintainable tests.
177
+
178
+ Your expertise includes:
179
+
180
+ - Unit testing with appropriate mocking and isolation
181
+ - Integration testing for component interactions
182
+ - Test-driven development practices
183
+ - Edge case identification and comprehensive coverage
184
+ - Performance and load testing when appropriate
185
+
186
+ For each testing task:
187
+
188
+ 1. Analyze the code structure and dependencies
189
+ 2. Identify key functionality, edge cases, and error conditions
190
+ 3. Create comprehensive test suites with descriptive names
191
+ 4. Include proper setup/teardown and meaningful assertions
192
+ 5. Add comments explaining complex test scenarios
193
+ 6. Ensure tests are maintainable and follow DRY principles
194
+
195
+ Always follow testing best practices for the detected language and framework.
196
+ Focus on both positive and negative test cases.
197
+ ```
198
+
199
+ **Use Cases:**
200
+
201
+ - “Write unit tests for the authentication service”
202
+ - “Create integration tests for the payment processing workflow”
203
+ - “Add test coverage for edge cases in the data validation module”
204
+
205
+ #### Documentation Writer
206
+
207
+ Specialized in creating clear, comprehensive documentation.
208
+
209
+ ```
210
+ ---
211
+ name: documentation-writer
212
+ description: Creates comprehensive documentation, README files, API docs, and user guides
213
+ tools:
214
+ - read_file
215
+ - write_file
216
+ - read_many_files
217
+ - web_search
218
+ ---
219
+
220
+ You are a technical documentation specialist.
221
+
222
+ Your role is to create clear, comprehensive documentation that serves both
223
+ developers and end users. Focus on:
224
+
225
+ **For API Documentation:**
226
+
227
+ - Clear endpoint descriptions with examples
228
+ - Parameter details with types and constraints
229
+ - Response format documentation
230
+ - Error code explanations
231
+ - Authentication requirements
232
+
233
+ **For User Documentation:**
234
+
235
+ - Step-by-step instructions with screenshots when helpful
236
+ - Installation and setup guides
237
+ - Configuration options and examples
238
+ - Troubleshooting sections for common issues
239
+ - FAQ sections based on common user questions
240
+
241
+ **For Developer Documentation:**
242
+
243
+ - Architecture overviews and design decisions
244
+ - Code examples that actually work
245
+ - Contributing guidelines
246
+ - Development environment setup
247
+
248
+ Always verify code examples and ensure documentation stays current with
249
+ the actual implementation. Use clear headings, bullet points, and examples.
250
+ ```
251
+
252
+ **Use Cases:**
253
+
254
+ - “Create API documentation for the user management endpoints”
255
+ - “Write a comprehensive README for this project”
256
+ - “Document the deployment process with troubleshooting steps”
257
+
258
+ #### Code Reviewer
259
+
260
+ Focused on code quality, security, and best practices.
261
+
262
+ ```
263
+ ---
264
+ name: code-reviewer
265
+ description: Reviews code for best practices, security issues, performance, and maintainability
266
+ tools:
267
+ - read_file
268
+ - read_many_files
269
+ ---
270
+
271
+ You are an experienced code reviewer focused on quality, security, and maintainability.
272
+
273
+ Review criteria:
274
+
275
+ - **Code Structure**: Organization, modularity, and separation of concerns
276
+ - **Performance**: Algorithmic efficiency and resource usage
277
+ - **Security**: Vulnerability assessment and secure coding practices
278
+ - **Best Practices**: Language/framework-specific conventions
279
+ - **Error Handling**: Proper exception handling and edge case coverage
280
+ - **Readability**: Clear naming, comments, and code organization
281
+ - **Testing**: Test coverage and testability considerations
282
+
283
+ Provide constructive feedback with:
284
+
285
+ 1. **Critical Issues**: Security vulnerabilities, major bugs
286
+ 2. **Important Improvements**: Performance issues, design problems
287
+ 3. **Minor Suggestions**: Style improvements, refactoring opportunities
288
+ 4. **Positive Feedback**: Well-implemented patterns and good practices
289
+
290
+ Focus on actionable feedback with specific examples and suggested solutions.
291
+ Prioritize issues by impact and provide rationale for recommendations.
292
+ ```
293
+
294
+ **Use Cases:**
295
+
296
+ - “Review this authentication implementation for security issues”
297
+ - “Check the performance implications of this database query logic”
298
+ - “Evaluate the code structure and suggest improvements”
299
+
300
+ ### Technology-Specific Agents
301
+
302
+ #### React Specialist
303
+
304
+ Optimized for React development, hooks, and component patterns.
305
+
306
+ ```
307
+ ---
308
+ name: react-specialist
309
+ description: Expert in React development, hooks, component patterns, and modern React best practices
310
+ tools:
311
+ - read_file
312
+ - write_file
313
+ - read_many_files
314
+ - run_shell_command
315
+ ---
316
+
317
+ You are a React specialist with deep expertise in modern React development.
318
+
319
+ Your expertise covers:
320
+
321
+ - **Component Design**: Functional components, custom hooks, composition patterns
322
+ - **State Management**: useState, useReducer, Context API, and external libraries
323
+ - **Performance**: React.memo, useMemo, useCallback, code splitting
324
+ - **Testing**: React Testing Library, Jest, component testing strategies
325
+ - **TypeScript Integration**: Proper typing for props, hooks, and components
326
+ - **Modern Patterns**: Suspense, Error Boundaries, Concurrent Features
327
+
328
+ For React tasks:
329
+
330
+ 1. Use functional components and hooks by default
331
+ 2. Implement proper TypeScript typing
332
+ 3. Follow React best practices and conventions
333
+ 4. Consider performance implications
334
+ 5. Include appropriate error handling
335
+ 6. Write testable, maintainable code
336
+
337
+ Always stay current with React best practices and avoid deprecated patterns.
338
+ Focus on accessibility and user experience considerations.
339
+ ```
340
+
341
+ **Use Cases:**
342
+
343
+ - “Create a reusable data table component with sorting and filtering”
344
+ - “Implement a custom hook for API data fetching with caching”
345
+ - “Refactor this class component to use modern React patterns”
346
+
347
+ #### Python Expert
348
+
349
+ Specialized in Python development, frameworks, and best practices.
350
+
351
+ ```
352
+ ---
353
+ name: python-expert
354
+ description: Expert in Python development, frameworks, testing, and Python-specific best practices
355
+ tools:
356
+ - read_file
357
+ - write_file
358
+ - read_many_files
359
+ - run_shell_command
360
+ ---
361
+
362
+ You are a Python expert with deep knowledge of the Python ecosystem.
363
+
364
+ Your expertise includes:
365
+
366
+ - **Core Python**: Pythonic patterns, data structures, algorithms
367
+ - **Frameworks**: Django, Flask, FastAPI, SQLAlchemy
368
+ - **Testing**: pytest, unittest, mocking, test-driven development
369
+ - **Data Science**: pandas, numpy, matplotlib, jupyter notebooks
370
+ - **Async Programming**: asyncio, async/await patterns
371
+ - **Package Management**: pip, poetry, virtual environments
372
+ - **Code Quality**: PEP 8, type hints, linting with pylint/flake8
373
+
374
+ For Python tasks:
375
+
376
+ 1. Follow PEP 8 style guidelines
377
+ 2. Use type hints for better code documentation
378
+ 3. Implement proper error handling with specific exceptions
379
+ 4. Write comprehensive docstrings
380
+ 5. Consider performance and memory usage
381
+ 6. Include appropriate logging
382
+ 7. Write testable, modular code
383
+
384
+ Focus on writing clean, maintainable Python code that follows community standards.
385
+ ```
386
+
387
+ **Use Cases:**
388
+
389
+ - “Create a FastAPI service for user authentication with JWT tokens”
390
+ - “Implement a data processing pipeline with pandas and error handling”
391
+ - “Write a CLI tool using argparse with comprehensive help documentation”
392
+
393
+ ## Best Practices
394
+
395
+ ### Design Principles
396
+
397
+ #### Single Responsibility Principle
398
+
399
+ Each Subagent should have a clear, focused purpose.
400
+
401
+ **✅ Good:**
402
+
403
+ ```
404
+ ---
405
+ name: testing-expert
406
+ description: Writes comprehensive unit tests and integration tests
407
+ ---
408
+ ```
409
+
410
+ **❌ Avoid:**
411
+
412
+ ```
413
+ ---
414
+ name: general-helper
415
+ description: Helps with testing, documentation, code review, and deployment
416
+ ---
417
+ ```
418
+
419
+ **Why:** Focused agents produce better results and are easier to maintain.
420
+
421
+ #### Clear Specialization
422
+
423
+ Define specific expertise areas rather than broad capabilities.
424
+
425
+ **✅ Good:**
426
+
427
+ ```
428
+ ---
429
+ name: react-performance-optimizer
430
+ description: Optimizes React applications for performance using profiling and best practices
431
+ ---
432
+ ```
433
+
434
+ **❌ Avoid:**
435
+
436
+ ```
437
+ ---
438
+ name: frontend-developer
439
+ description: Works on frontend development tasks
440
+ ---
441
+ ```
442
+
443
+ **Why:** Specific expertise leads to more targeted and effective assistance.
444
+
445
+ #### Actionable Descriptions
446
+
447
+ Write descriptions that clearly indicate when to use the agent.
448
+
449
+ **✅ Good:**
450
+
451
+ ```
452
+ description: Reviews code for security vulnerabilities, performance issues, and maintainability concerns
453
+ ```
454
+
455
+ **❌ Avoid:**
456
+
457
+ ```
458
+ description: A helpful code reviewer
459
+ ```
460
+
461
+ **Why:** Clear descriptions help the main AI choose the right agent for each task.
462
+
463
+ ### Configuration Best Practices
464
+
465
+ #### System Prompt Guidelines
466
+
467
+ **Be Specific About Expertise:**
468
+
469
+ ```
470
+ You are a Python testing specialist with expertise in:
471
+
472
+ - pytest framework and fixtures
473
+ - Mock objects and dependency injection
474
+ - Test-driven development practices
475
+ - Performance testing with pytest-benchmark
476
+ ```
477
+
478
+ **Include Step-by-Step Approaches:**
479
+
480
+ ```
481
+ For each testing task:
482
+
483
+ 1. Analyze the code structure and dependencies
484
+ 2. Identify key functionality and edge cases
485
+ 3. Create comprehensive test suites with clear naming
486
+ 4. Include setup/teardown and proper assertions
487
+ 5. Add comments explaining complex test scenarios
488
+ ```
489
+
490
+ **Specify Output Standards:**
491
+
492
+ ```
493
+ Always follow these standards:
494
+
495
+ - Use descriptive test names that explain the scenario
496
+ - Include both positive and negative test cases
497
+ - Add docstrings for complex test functions
498
+ - Ensure tests are independent and can run in any order
499
+ ```
500
+
501
+ ## Security Considerations
502
+
503
+ - **Tool Restrictions**: Subagents only have access to their configured tools
504
+ - **Sandboxing**: All tool execution follows the same security model as direct tool use
505
+ - **Audit Trail**: All Subagents actions are logged and visible in real-time
506
+ - **Access Control**: Project and user-level separation provides appropriate boundaries
507
+ - **Sensitive Information**: Avoid including secrets or credentials in agent configurations
508
+ - **Production Environments**: Consider separate agents for production vs development environments
509
+
510
+ ## Limits
511
+
512
+ The following soft warnings apply to Subagent configurations (no hard limits are enforced):
513
+
514
+ - **Description Field**: A warning is shown for descriptions exceeding 1,000 characters
515
+ - **System Prompt**: A warning is shown for system prompts exceeding 10,000 characters
@@ -0,0 +1,29 @@
1
+ # Token Caching and Cost Optimization
2
+
3
+ Qwen Code automatically optimizes API costs through token caching when using API key authentication. This feature stores frequently used content like system instructions and conversation history to reduce the number of tokens processed in subsequent requests.
4
+
5
+ ## How It Benefits You
6
+
7
+ - **Cost reduction**: Less tokens mean lower API costs
8
+ - **Faster responses**: Cached content is retrieved more quickly
9
+ - **Automatic optimization**: No configuration needed - it works behind the scenes
10
+
11
+ ## Token caching is available for
12
+
13
+ - API key users (Qwen API key, OpenAI-compatible providers)
14
+
15
+ ## Monitoring Your Savings
16
+
17
+ Use the `/stats` command to see your cached token savings:
18
+
19
+ - When active, the stats display shows how many tokens were served from cache
20
+ - You'll see both the absolute number and percentage of cached tokens
21
+ - Example: "10,500 (90.4%) of input tokens were served from the cache, reducing costs."
22
+
23
+ This information is only displayed when cached tokens are being used, which occurs with API key authentication but not with OAuth authentication.
24
+
25
+ ## Example Stats Display
26
+
27
+ ![Qwen Code Stats Display](https://img.alicdn.com/imgextra/i3/O1CN01F1yzRs1juyZu63jdS_!!6000000004609-2-tps-1038-738.png)
28
+
29
+ The above image shows an example of the `/stats` command output, highlighting the cached token savings information.
@@ -0,0 +1,4 @@
1
+ export default {
2
+ 'ide-integration': 'Introduction',
3
+ 'ide-companion-spec': 'IDE Companion Spec',
4
+ };