You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Set up pre-commit hooks with ruff, mypy, and tests
- Add .pre-commit-config.yaml with ruff formatting, mypy type checking, and test validation
- Install pre-commit as dev dependency
- Fix all type annotations in test file
- Update chrome_management.py to use consistent cdp_client injection pattern
- Add pre-commit targets to Makefile
- Update README with pre-commit documentation
- All pre-commit hooks now pass: ruff, mypy, pytest
You are an expert coding assistant. This documents some of our ways of working and things you should adhere to.
2
+
3
+
# General Principles
4
+
5
+
- Write in British English at all times, for docs and code.
6
+
- Write clean, functional code and minimise the use of abstraction.
7
+
- Follow DRY principles.
8
+
- Be modular and build for extensibility.
9
+
- When you write code, you should follow TDD and start with a unit test to describe the behaviour you're trying to acheive. You should then write the code that passes the test, with the desired functionality.
10
+
- You should always provide good documentation with examples.
11
+
- If you're unsure about an API or SDK, search the web for official docs and guidance.
12
+
13
+
# Tool use
14
+
15
+
Sometimes you will need to call upon other tools to perform certain tasks, here's a cheatsheet for what you should reach for in certain scenarios:
16
+
17
+
- Looking for text and strings in files: rg
18
+
- Looking more specificially for code-aware / structural find and replace: ast-grep
19
+
- Looking for files or directories: fd
20
+
- When narrowing down options, pipe other commands into: fzf
I want to build this as a Desktop Extension, abbreviated as "DXT". Please follow these steps:
2
+
3
+
Read the specifications thoroughly:
4
+
https://github.com/anthropics/dxt/blob/main/README.md - DXT architecture overview, capabilities, and integration patterns
5
+
https://github.com/anthropics/dxt/blob/main/MANIFEST.md - Complete extension manifest structure and field definitions
6
+
https://github.com/anthropics/dxt/tree/main/examples - Reference implementations including a "Hello World" example
7
+
Create a proper extension structure:
8
+
Generate a valid manifest.json following the MANIFEST.md spec
9
+
Implement an MCP server using @modelcontextprotocol/sdk with proper tool definitions
10
+
Include proper error handling, security measures, and timeout management
11
+
Follow best development practices:
12
+
Implement proper MCP protocol communication via stdio transport
13
+
Structure tools with clear schemas, validation, and consistent JSON responses
14
+
Make use of the fact that this extension will be running locally
15
+
Add appropriate logging and debugging capabilities
16
+
Include proper documentation and setup instructions
17
+
Test considerations:
18
+
Validate that all tool calls return properly structured responses
19
+
Verify manifest loads correctly and host integration works
20
+
Generate complete, production-ready code that can be immediately tested. Focus on defensive programming, clear error messages, and following the exact DXT specifications to ensure compatibility with the ecosystem.
21
+
22
+
Recent Updates:
23
+
- Updated use of CDP in the app and general tidying
0 commit comments