A merged and expanded collection of developer workflows for the interactive shell.
You: Review this Python function and suggest improvements:
def process_data(data):
result = []
for item in data:
if item > 0:
result.append(item * 2)
return result
You: This function is slow, please help optimize it:
[paste function code]
You: /run python3 -m cProfile myscript.py
You: What's the bottleneck?
You: How do I implement async/await correctly in Python?
You: /run python3 examples/async_example.py
You: I'm getting AttributeError when iterating. Here's the code:
[... paste code ...]
You: /run python3 -m pdb myscript.py
You: My React component keeps re-rendering infinitely.
You: [Paste component code]
Assistant: [Detailed explanation with fixes]
You: Design a RESTful API for a todo app with:
- User authentication
- Task management
- Sharing between users
You: /run sqlite3 mydb.db
You: Optimize this query:
SELECT * FROM users WHERE email LIKE '%@gmail.com%'
You: How do I implement background tasks in Swift?
You: Create a safe example with error handling.
You: My React Native app crashes on startup.
You: /run adb logcat
You: [Paste the crash logs]
You: How can I securely authenticate API requests from a mobile app?
You: /mode review
You: Is this password hashing secure?
password_hash = hashlib.md5(password.encode()).hexdigest()
You: How do I prevent SQL injection in this code?
You: [Paste your query code]
You: Audit this API authentication flow and recommend security improvements.
You: /mode devops
You: Help me create a Dockerfile for a Node.js application.
You: Also create docker-compose.yml for local development.
You: Design a GitHub Actions workflow for:
- Running tests
- Building a Docker image
- Deploying to AWS
You: My pod keeps crashing. Here is the error log:
[Paste logs]
You: /run kubectl describe pod myapp-pod
You: /run tail -n 50 /var/log/nginx/error.log
You: Why am I seeing 502 Bad Gateway errors?
You: I'm getting a KeyError when grouping. Here's the code:
df.groupby('category')['value'].sum()
You: My neural network validation loss is increasing while training loss decreases.
You: Here's my model architecture:
[Paste model code]
You: Optimize this slow query:
SELECT * FROM transactions t1
WHERE t1.date > NOW() - INTERVAL 1 YEAR
AND EXISTS (SELECT 1 FROM users u WHERE u.id = t1.user_id)
You: Explain how the Vue 3 Composition API works.
You: Show an example of ref and reactive.
You: How do I use lifecycle hooks?
You: Explain the Factory Pattern in Python.
You: Give a code example.
You: Explain how quicksort works.
You: Show a Python implementation.
You: What's the time complexity?
You: I have a bug but don't know where.
You: /run python3 -m pdb script.py
You: Help me trace the execution.
You: My application keeps using more memory.
You: /run python3 -m memory_profiler script.py
You: [Paste output]
You: This function is slow:
[Paste function]
You: /run python3 -m cProfile myscript.py
You: What's the bottleneck?
You: Plan a semantic versioning release for my project.
You: Current version: 2.5.3
You: Changes: [new feature], [bug fix], [performance improvement]
You: Design a database migration strategy for:
- Adding a new column
- Migrating data
- Ensuring zero downtime
You: What's a good rollback strategy for microservices?
You: How do I handle database rollbacks?
You: Here's our current microservices architecture:
[Describe services]
You: How can we improve scalability?
You: What about resilience?
You: We're choosing between Node.js and Go for our backend.
You: Requirements: [list requirements]
You: Which would you recommend and why?
You: /run pylint mymodule.py
You: Help me improve the code quality score.
Quick Code Review:
You: Review this code for bugs:
[paste code]
Quick Learning:
You: Explain [concept] in Python.
Quick Debugging:
You: /run python3 debug_script.py
You: Why is this failing?
Quick Execution:
You: /run npm test
You: /run python3 manage.py migrate
You: /run make build
- Use
/runfor command output - Execute scripts and show results. - Paste full context - More code means better advice.
- Use
/history- Review previous conversation context. - Use
/clear- Reset history for new topics. - Ask follow-up questions - Build on previous results.
- Be specific - "Fix this slow query" is better than "Help me".
You: Review my PR changes:
You: [Paste code]
You: Any security concerns?
You: Performance issues?
You: Better patterns?
You: Teach me about async/await.
You: Show examples.
You: Common pitfalls?
You: /run python3 # Try examples
You: Bug: Can't connect to database.
You: Here's the error:
[Paste full error]
You: Here's my connection code:
[Paste code]
You: /run python3 test_connection.py
You: /run python3 -c "print('Hello')"
You: Explain the output.
You: How can I modify it to do X?
You: [Ask first question]
You: [Follow-up question uses previous context]
You: [Another related question]
Use /clear when starting a new unrelated topic.
You: How do I do this in Python?
You: How about in Go?
You: Which is better for X use case?
For more information, see README.md and QUICKSTART.md