docs: add agent rules example to README#655
Conversation
Add a new example section demonstrating GraphQL batching configuration in agent-orchestrator.yaml. This example shows how to enable batch queries for projects using GraphQL APIs. Closes #650
There was a problem hiding this comment.
Pull request overview
Adds a new documentation section to the README intended to show how to configure GraphQL request batching in agent-orchestrator.yaml.
Changes:
- Added a “GraphQL Batching Example” section under Configuration
- Included a YAML snippet demonstrating
batchQueries,maxBatchSize, andbatchInterval
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ### GraphQL Batching Example | ||
|
|
||
| For projects that use GraphQL, you can configure the orchestrator to batch related queries and mutations for efficiency: | ||
|
|
||
| ```yaml | ||
| # agent-orchestrator.yaml | ||
| projects: | ||
| my-graphql-app: | ||
| repo: owner/my-graphql-app | ||
| path: ~/my-graphql-app | ||
| defaultBranch: main | ||
| settings: | ||
| graphql: | ||
| batchQueries: true | ||
| maxBatchSize: 10 | ||
| batchInterval: 100ms | ||
| ``` | ||
|
|
||
| This configuration enables automatic batching of GraphQL requests when the agent interacts with your GraphQL API, reducing network overhead and improving performance. | ||
|
|
There was a problem hiding this comment.
The README introduces projects.<id>.settings.graphql with batchQueries/maxBatchSize/batchInterval and claims the orchestrator will batch GraphQL requests, but these keys don’t appear to exist in the current configuration schema (e.g., ProjectConfig in packages/core/src/types.ts and agent-orchestrator.yaml.example don’t define a settings or graphql section). As written, this example will likely produce an “unknown config key”/validation error and mislead users. Please either (1) update the example to use real, supported config fields, or (2) land the corresponding config + implementation changes and add the new fields to the schema/example config before documenting them here.
| ### GraphQL Batching Example | |
| For projects that use GraphQL, you can configure the orchestrator to batch related queries and mutations for efficiency: | |
| ```yaml | |
| # agent-orchestrator.yaml | |
| projects: | |
| my-graphql-app: | |
| repo: owner/my-graphql-app | |
| path: ~/my-graphql-app | |
| defaultBranch: main | |
| settings: | |
| graphql: | |
| batchQueries: true | |
| maxBatchSize: 10 | |
| batchInterval: 100ms | |
| ``` | |
| This configuration enables automatic batching of GraphQL requests when the agent interacts with your GraphQL API, reducing network overhead and improving performance. |
Replace non-existent GraphQL batching config with a valid agentRules example that uses supported ProjectConfig fields. Addresses review comment on PR #655.
|
Thanks for catching that! I've updated the example to use a valid agentRules configuration field that exists in the ProjectConfig schema. The new example demonstrates how to define agent-specific coding conventions that will be included in every agent prompt. |
Summary
agentRulesfor project-specific coding conventionsTest plan
Closes #650