Skip to content

Commit 91b443b

Browse files
authored
Merge pull request #194 from AccelerationConsortium/sgbaird-patch-8
Create copilot-instructions.md with guidelines
2 parents 7b406c6 + d209e95 commit 91b443b

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

.github/copilot-instructions.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
## Development Practices
2+
3+
- Start with minimal, lean implementations focused on proof-of-concept
4+
- Avoid creating new files until asked
5+
- Avoid implementing things from scratch
6+
- Avoid defensive error handling for hypothetical failures
7+
- Use print statements and logging sparingly, unless asked
8+
- Avoid light wrappers and custom classes, unless asked
9+
- Avoid `if __name__ == "__main__"` patterns in package code, unless asked
10+
For example, rather than using:
11+
```python
12+
from math import sqrt
13+
def main():
14+
sqrt(2)
15+
16+
if __name__ == "__main__":
17+
main()
18+
```
19+
Leave it as a top-level script:
20+
```python
21+
from math import sqrt
22+
sqrt(2)
23+
```
24+
- Skip unit tests unless explicitly requested
25+
- Follow patterns in CONTRIBUTING.md when present
26+
- Prefer writing Python if no language specified
27+
- For complex code changes, use your Serena MCP tools (e.g., `find_symbol`, `find_referencing_symbols`, and `insert_after_symbol`) for symbol-based code editing instead of always relying on regex for code modifications
28+
29+
## Git Operations
30+
31+
- When asked to remove all file changes, use `git checkout -- <filename>`
32+
- Copy-paste commands you run and summarized execution status directly in your comment replies
33+
34+
## External Resources
35+
36+
- Validate and access link content using your available MCP tools (Playwright and/or Perplexity)
37+
- Search GitHub for relevant open-source alternatives to commercial tools
38+
- Prioritize official package documentation over inferred usage by using your Context7 MCP tool
39+
40+
## Communication Style
41+
42+
- Use minimal emoji and special symbols
43+
- Prioritize clarity and brevity in responses
44+
- Ask clarifying questions when needed
45+
- Don't infer requirements or create workarounds unless asked
46+
- Put documentation content in comment replies, not separate files, unless asked
47+
- Comments should not leave a trace of the development process
48+
- Avoid sycophancy, favor objectiveness
49+
50+
## Change Logging
51+
52+
- Create CHANGELOG.md if it doesn't exist
53+
- Each time you generate code, note the changes in CHANGELOG.md
54+
- Follow semantic versioning guidelines
55+
- Include date and description of changes
56+
57+
## Coding Agent
58+
59+
- Set environment variables `PIP_TIMEOUT=600` and `PIP_RETRIES=2` prior to `conda` or `pip` installs
60+
- Include plots directly in your comment reply via `![image name](https://github.com/<user/org>/<repo>/blob/<shortened-commit-hash>/<filename>?raw=true)`. Truncate the commit hash to the first 7 characters only. For example, `https://github.com/AccelerationConsortium/evaluation-metrics/blob/52754e7/scripts/bo_benchmarks/demonstrations/branin_campaign_demonstration_results.png?raw=true`. For provenance, ensure you use the shortened (7-character) commit hash, not the branch name
61+
- If you mention files in your comment reply, add direct hyperlinks based on the shortened (7-character) commit hash

0 commit comments

Comments
 (0)