krishna-devli/slug icon
public
Published on 4/29/2025
Mitra

Hello there this is second .

Rules
Prompts
Models
Context
Data
relace Relace Instant Apply model icon

Relace Instant Apply

relace

anthropic Claude 3.5 Sonnet model icon

Claude 3.5 Sonnet

anthropic

200kinput·8.192koutput
voyage voyage-code-3 model icon

voyage-code-3

voyage

voyage Voyage AI rerank-2 model icon

Voyage AI rerank-2

voyage

together Llama 4 Maverick Instruct (17Bx128E) model icon

Llama 4 Maverick Instruct (17Bx128E)

together

gemini Gemini 2.0 Flash model icon

Gemini 2.0 Flash

gemini

1048kinput·8.192koutput
voyage voyage-code-2 model icon

voyage-code-2

voyage

ollama qwen2.5-coder 1.5b model icon

qwen2.5-coder 1.5b

ollama

lmstudio deepseek-r1 8b model icon

deepseek-r1 8b

lmstudio

novita llama-3.3-70b-instruct model icon

llama-3.3-70b-instruct

novita

deepinfra Qwen2.5 Coder 32B Instruct model icon

Qwen2.5 Coder 32B Instruct

deepinfra

ollama deepseek-r1 8b model icon

deepseek-r1 8b

ollama

sambanova DeepSeek R1 model icon

DeepSeek R1

sambanova

deepinfra DeepSeek R1 model icon

DeepSeek R1

deepinfra

novita deepseek-r1 model icon

deepseek-r1

novita

## Core Principles:
  - Optimize for Hydrogens **streaming and caching** model to enhance performance.
  - Use **Shopifys Storefront API** effectively, following best practices for queries and mutations.
  - Ensure all components are **server-first** but leverage **client-side hydration** where needed.
  - Use **Tailwind CSS** efficiently with Hydrogens best practices for styling.
  - Prioritize **authentication and session handling** for Shopify customers.

## Routing & Layout in Remix
  - Use `loader` functions for **server-side data fetching**.
  - Prefer **nested routes** for modular page structures.
  - Use `useLoaderData()` instead of client-side fetching where possible.
  - Optimize Remixs **deferred loading** to improve perceived performance.

## Shopify Storefront API Usage
  - Always fetch data using **GraphQL queries** in `loader` functions.
  - Minimize API requests by batching queries efficiently.
  - Cache queries where appropriate to **reduce unnecessary API calls**.
  - Avoid over-fetching request **only the necessary fields**.
  - Use Shopifys **recommended pagination techniques** (`cursor`-based pagination).

## Hydrogen & Performance Optimizations
  - Utilize **Hydrogens streaming API** to improve time-to-first-byte (TTFB).
  - Use `CacheNone()` or `CacheLong()` selectively to control caching behavior.
  - Edge caching Ensure frequently accessed data is cached at the CDN level.
  - Prefer `useShopQuery()` over manual API calls for **consistent data fetching**.
  - Offload **expensive computations to server-side** where possible.

## Styling & Tailwind CSS
  - Use **Hydrogens built-in Tailwind setup** for consistency.
  - Avoid excessive utility classes by leveraging **Tailwinds theme and variants**.
  - Structure styles efficiently to **minimize CSS bloat**.
  - Use **Tailwinds responsive utilities** to ensure a mobile-first approach.

## Authentication & Session Handling
  - Implement Shopifys **customer authentication** using `customerAccessToken`.
  - Store authentication tokens securely in **server-side sessions**.
  - Use Remix loaders and actions to **handle login and logout server-side**.
  - Ensure **session expiry is handled gracefully** to prevent errors.
  - Implement **SSR-friendly authentication checks** to avoid hydration mismatches.

## Deployment on Shopify Oxygen
  - Follow **Shopifys guidelines for edge deployment**.
  - Ensure **Remix server handlers** are optimized for Oxygen.
  - Use `@shopify/hydrogen` utilities for **seamless integration with Shopify's infrastructure**.
  - Test deployments using Shopifys **Oxygen preview environment** before production.

## Component & Code Best Practices
  - Prefer **server components** whenever possible to reduce client-side JavaScript.
  - Use **lazy loading** (`React.lazy()`, `Suspense`) for non-critical UI components.
  - Keep components **small, modular, and reusable**.
  - Avoid excessive **client-side state management**; leverage Remix loaders instead.
  - Use **React Error Boundaries** for graceful error handling.

## Key Conventions:
  - Always **fetch data in loaders**; minimize client-side API calls.
  - Structure routes **to take full advantage of Remixs nested routing**.
  - Use **server caching strategies** to reduce redundant Storefront API calls.
  - Optimize **Hydrogens streaming features** for a fast user experience.
  - Follow **Shopifys best practices for deployment on Oxygen**.

Refer to Shopifys Hydrogen and Remix documentation for additional best practices.
Angular Docshttps://angular.io/docs
Nuxt.jshttps://nuxt.com/docs
PyTorchhttps://pytorch.org/docs/stable/index.html
Sveltehttps://svelte.dev/docs/svelte
Zodhttps://zod.dev/
Next.jshttps://nextjs.org/docs/app
Symfony Docshttps://symfony.com/doc/current/index.html
Pandashttps://pandas.pydata.org/docs/
Langchain Docshttps://python.langchain.com/docs/introduction/
NumPyhttps://numpy.org/doc/stable/
Reacthttps://react.dev/reference/
Rust docshttps://doc.rust-lang.org/book/
Vercel AI SDK Docshttps://sdk.vercel.ai/docs/

Prompts

Learn more
New Component
Create a new Angular component
Please create a new Angular component following these guidelines:
- Include JSDoc comments for component and inputs/outputs
- Implement proper lifecycle hooks
- Include TypeScript interfaces for models
- Follow container/presentational component pattern where appropriate
- Include unit tests with Jasmine/Karma in a separate test file
- Make sure to create separate files for any services, pipes, modules, and directives
Page
Creates a new Nuxt.js page based on the description provided.
Create a new Nuxt.js page based on the following description.
New Module
Create a new PyTorch module
Please create a new PyTorch module following these guidelines:
- Include docstrings for the model class and methods
- Add type hints for all parameters
- Add basic validation in __init__
New Component
Create a new Svelte component
Please create a new Svelte component following these guidelines:
- Include JSDoc comments for component and props
- Include basic error handling and loading states
- ALWAYS add a TypeScript prop interface
Page
Creates a new Next.js page based on the description provided.
Create a new Next.js page based on the following description.
Review
Review changes
Please review the current code changes looking for:

- Memory leaks (unsubscribed observables)
- Proper change detection strategy
- Proper use of async pipe
- Proper error handling

Format the review as:
```
## <FILENAME>
- <ISSUE>
...
- <ISSUE>
```
Exploratory Data Analysis
Initial data exploration and key insights
Create an exploratory data analysis workflow that includes:

Data Overview:
- Basic statistics (mean, median, std, quartiles)
- Missing values and data types
- Unique value distributions

Visualizations:
- Numerical: histograms, box plots
- Categorical: bar charts, frequency plots
- Relationships: correlation matrices
- Temporal patterns (if applicable)

Quality Assessment:
- Outlier detection
- Data inconsistencies
- Value range validation

Insights & Documentation:
- Key findings summary
- Data quality issues
- Variable relationships
- Next steps recommendations
- Reproducible Jupyter notebook

The user has provided the following information:
Write Unit Test
Write Laravel Unit Tests for attached code
Use Laravel to write a comprehensive suite of unit tests for the attached code.
Ensure that your responses are concise and technical, providing precise PHP examples that adhere to Laravel best practices and conventions. Apply object-oriented programming principles with a focus on SOLID design, prioritizing code iteration and modularization over duplication.
When writing unit tests, select descriptive names for test methods and variables, and use directories in lowercase with dashes following Laravel's conventions (e.g., app/Http/Controllers). Prioritize the use of dependency injection and service containers to create maintainable code that leverages PHP 8.1+ features.
Conform to PSR-12 coding standards and enforce strict typing using declare(strict_types=1);. Utilize Laravel's testing tools, particularly PHPUnit, to efficiently construct tests that validate the code functionality. Implement error handling and logging in your tests using Laravel's built-in features, and employ middleware testing techniques for request filtering and modification validation.
Ensure that your test cases cover the interactions using Laravel's Eloquent ORM and query builder, applying suitable practices for database migrations and seeders in a testing environment. Manage dependencies using the latest stable versions of Laravel and Composer, and rely on Eloquent ORM over raw SQL queries wherever applicable.
Adopt the Repository pattern for testing the data access layer, utilize Laravel's built-in authentication and authorization features in your tests, and implement job queue scenarios for long-running task verifications. Incorporate API versioning checks for endpoint tests and use Laravel's localization features to simulate multi-language support.
Use Laravel Mix in your testing workflow for asset handling and ensure efficient indexing for database operations tested within your suite. Leverage Laravel's pagination features and implement comprehensive error logging and monitoring in your test scenarios. Follow Laravel's MVC architecture, ensure route definitions are verified through tests, and employ Form Requests for validating request data.
Utilize Laravel's Blade engine during the testing of view components and confirm the establishment of database relationships through Eloquent. Implement API resource transformations and mock event and listener systems to maintain decoupled code functionality in your tests. Finally, utilize database transactions during tests to ensure data integrity, and use Laravel's scheduling features to validate recurring tasks.
RAG Pipeline Design
Comprehensive retrieval-augmented generation system design
Design a RAG (Retrieval-Augmented Generation) system with:

Document Processing:
- Text extraction strategy
- Chunking approach with size and overlap parameters
- Metadata extraction and enrichment
- Document hierarchy preservation

Vector Store Integration:
- Embedding model selection and rationale
- Vector database architecture
- Indexing strategy
- Query optimization

Retrieval Strategy:
- Hybrid search (vector + keyword)
- Re-ranking methodology
- Metadata filtering capabilities
- Multi-query reformulation

LLM Integration:
- Context window optimization
- Prompt engineering for retrieval
- Citation and source tracking
- Hallucination mitigation strategies

Evaluation Framework:
- Retrieval relevance metrics
- Answer accuracy measures
- Ground truth comparison
- End-to-end benchmarking

Deployment Architecture:
- Caching strategies
- Scaling considerations
- Latency optimization
- Monitoring approach

The user's knowledge base has the following characteristics:
Prisma schema
Create a Prisma schema.
Create or update a Prisma schema with the following models and relationships. Include necessary fields, relationships, and any relevant enums.
API route inspection
Analyzes API routes for security issues
Review this API route for security vulnerabilities. Ask questions about the context, data flow, and potential attack vectors. Be thorough in your investigation.
Client component
Create a client component.
Create a client component with the following functionality. If writing this as a server component is not possible, explain why.

Context

Learn more
@diff
Reference all of the changes you've made to your current branch
@codebase
Reference the most relevant snippets from your codebase
@url
Reference the markdown converted contents of a given URL
@folder
Uses the same retrieval mechanism as @Codebase, but only on a single folder
@terminal
Reference the last command you ran in your IDE's terminal and its output
@code
Reference specific functions or classes from throughout your project
@file
Reference any file in your current workspace

S3

${{ secrets.krishna-devli/slug/continuedev/s3-dev-data/AWS_SERVER_URL }}

New Relic

https://log-api.newrelic.com/log/v1

Google Cloud Storage

${{ secrets.krishna-devli/slug/continuedev/google-cloud-storage-dev-data/GCP_SERVER_URL }}

MCP Servers

Learn more

Exa

npx -y exa-mcp-server

Docker MCP Postgres

docker run -i --rm mcp/postgres ${{ secrets.krishna-devli/slug/docker/mcp-postgres/POSTGRES_CONNECTION_STRING }}

Memory

npx -y @modelcontextprotocol/server-memory

Playwright

npx -y @executeautomation/playwright-mcp-server

Browser MCP

npx -y @browsermcp/mcp@latest

Docker MCP Slack

docker run -i --rm -e SLACK_BOT_TOKEN -e SLACK_TEAM_ID mcp/slack

Postgres

npx -y @modelcontextprotocol/server-postgres ${{ secrets.krishna-devli/slug/anthropic/postgres-mcp/CONNECTION_STRING }}

Docker MCP Sequential Thinking

docker run --rm -i mcp/sequentialthinking

Repomix

npx -y repomix --mcp

GitHub

npx -y @modelcontextprotocol/server-github

Docker MCP Git

docker run --rm -i --mount type=bind,src=${{ secrets.krishna-devli/slug/docker/mcp-git/GIT_DIR }},dst=${{ secrets.krishna-devli/slug/docker/mcp-git/GIT_DIR }} mcp/git

Tavily Search

npx -y tavily-mcp@0.1.4

Filesystem

npx -y @modelcontextprotocol/server-filesystem ${{ secrets.krishna-devli/slug/anthropic/filesystem-mcp/PATH }}

Docker MCP Github

docker run -i --rm -e GITHUB_PERSONAL_ACCESS_TOKEN mcp/github

Brave Search

npx -y @modelcontextprotocol/server-brave-search

Stakpak

npx @stakpak/mcp@latest --output=text

Docker MCP Gitlab

docker run -e GITLAB_PERSONAL_ACCESS_TOKEN -e GITLAB_API_URL mcp/gitlab