home / skills / z980944038-dev / openclawwdl / byterover-1.2.2

byterover-1.2.2 skill

/skills/byterover-1.2.2

This skill helps you retrieve and curate project knowledge using ByteRover context tree to accelerate understanding and knowledge persistence.

npx playbooks add skill z980944038-dev/openclawwdl --skill byterover-1.2.2

Review the files below or copy the command above to add this skill to your agents.

Files (4)
SKILL.md
3.6 KB
---
name: byterover
description: "Manages project knowledge using ByteRover context tree. Provides two operations: query (retrieve knowledge) and curate (store knowledge). Invoke when user requests information lookup, pattern discovery, or knowledge persistence. Developed by ByteRover Inc. (https://byterover.dev/)"
metadata:
  author: ByteRover Inc. (https://byterover.dev/)
  version: "1.2.1"
---

# ByteRover Context Tree

A project-level knowledge repository that persists across sessions. Use it to avoid re-discovering patterns, conventions, and decisions.

## Why Use ByteRover

- **Query before working**: Get existing knowledge about patterns, conventions, and past decisions before implementing
- **Curate after learning**: Capture insights, decisions, and bug fixes so future sessions start informed

## Quick Reference

| Command | When | Example |
|---------|------|---------|
| `brv query "question"` | Before starting work | `brv query "How is auth implemented?"` |
| `brv curate "context" -f file` | After completing work | `brv curate "JWT 24h expiry" -f auth.ts` |
| `brv status` | To check prerequisites | `brv status` |

## When to Use

**Query** when you need to understand something:
- "How does X work in this codebase?"
- "What patterns exist for Y?"
- "Are there conventions for Z?"

**Curate** when you learned or created something valuable:
- Implemented a feature using specific patterns
- Fixed a bug and found root cause
- Made an architecture decision

## Curate Quality

Context must be **specific** and **actionable**:

```bash
# Good - specific, explains where and why
brv curate "Auth uses JWT 24h expiry, tokens in httpOnly cookies" -f src/auth.ts

# Bad - too vague
brv curate "Fixed auth"
```

**Note:** Context argument must come before `-f` flags. Max 5 files.

## Best Practices

1. **Break down large contexts** - Run multiple `brv curate` commands for complex topics rather than one massive context. Smaller chunks are easier to retrieve and update.

2. **Let ByteRover read files** - Don't read files yourself before curating. Use `-f` flags to let ByteRover read them directly:
   ```bash
   # Good - ByteRover reads the files
   brv curate "Auth implementation details" -f src/auth.ts -f src/middleware/jwt.ts

   # Wasteful - reading files twice
   # [agent reads files] then brv curate "..." -f same-files
   ```

3. **Be specific in queries** - Queries block your workflow. Use precise questions to get faster, more relevant results:
   ```bash
   # Good - specific
   brv query "What validation library is used for API request schemas?"

   # Bad - vague, slow
   brv query "How is validation done?"
   ```

4. **Signal outdated context** - When curating updates that replace existing knowledge, explicitly tell ByteRover to clean up:
   ```bash
   brv curate "OUTDATED: Previous auth used sessions. NEW: Now uses JWT with refresh tokens. Clean up old session-based auth context." -f src/auth.ts
   ```

5. **Specify structure expectations** - Guide ByteRover on how to organize the knowledge:
   ```bash
   # Specify topics/domains
   brv curate "Create separate topics for: 1) JWT validation, 2) refresh token flow, 3) logout handling" -f src/auth.ts

   # Specify detail level
   brv curate "Document the error handling patterns in detail (at least 30 lines covering all error types)" -f src/errors/
   ```

## Prerequisites

Run `brv status` first. If errors occur, the agent cannot fix them—instruct the user to take action in their brv terminal. See [TROUBLESHOOTING.md](TROUBLESHOOTING.md) for details.

---

**See also:** [WORKFLOWS.md](WORKFLOWS.md) for detailed patterns and examples, [TROUBLESHOOTING.md](TROUBLESHOOTING.md) for error handling

Overview

This skill manages project-level knowledge using the ByteRover context tree. It provides two primary operations: query to retrieve existing knowledge and curate to persist new knowledge. Use it to avoid re-discovering patterns, conventions, and past decisions across sessions.

How this skill works

The skill inspects and organizes small, focused pieces of project context into a persistent tree so future sessions can retrieve them quickly. Invoke brv query to ask precise questions about patterns, conventions, or past decisions. Use brv curate with file flags to store specific, actionable context that ByteRover reads directly and indexes for later retrieval. Run brv status first to verify prerequisites are met.

When to use it

  • Before starting work, run brv query to learn existing patterns or conventions
  • When you need a quick answer about implementation details (libraries, validation, auth flows)
  • After completing work or debugging, run brv curate to persist what you learned
  • When replacing or deprecating old approaches—curate an OUTDATED note and the new approach
  • When you want team knowledge to persist across sessions and avoid repeated discovery

Best practices

  • Keep curated contexts small and focused; split large topics into multiple entries
  • Let ByteRover read files using -f flags instead of copying file contents into the message
  • Make queries specific to reduce time and increase relevance
  • When updating knowledge, mark old context as OUTDATED and provide cleanup guidance
  • Specify expected structure or detail level when curating (topics, lines of detail, scopes)

Example use cases

  • Query the codebase: brv query "How is auth implemented?" to learn auth flow and token handling
  • Curate a bug fix: brv curate "Fixed token refresh race causing logout" -f src/auth.ts
  • Document decisions: brv curate "JWT 24h expiry; tokens in httpOnly cookies" -f src/auth.ts
  • Capture conventions: brv curate "API validation uses Zod schemas in src/schemas" -f src/schemas/
  • Deprecate old patterns: brv curate "OUTDATED: Session-based auth. NEW: JWT with refresh tokens. Clean old contexts." -f src/auth.ts

FAQ

What should I include in a curate entry?

Include specific, actionable context that explains where and why a pattern exists, and attach related files with -f. Avoid vague summaries.

Why run brv status first?

brv status ensures prerequisites and agent connectivity are healthy; if errors appear, fix them in your terminal so the agent can operate correctly.