cline:latex - chunhualiao/public-docs GitHub Wiki

cline

Specific Prompting

When asking Cline to help with LaTeX papers, use specific prompting techniques:

For example:

  • "Create a LaTeX document structure for a research paper on [topic]"
  • "Help me format this equation in LaTeX: [equation]"
  • "Generate a BibTeX entry for this paper: [paper details]"

Custom instructions

The most effective way to tailor Cline for LaTeX papers is by adding custom instructions in the VS Code extension settings:

  • Open VS Code
  • Click the Cline extension settings dial ⚙️
  • Find the "Custom Instructions" field
  • Add LaTeX-specific instructions README.md:6-14
  • Your custom instructions should include LaTeX best practices, document structure preferences, and citation styles. These instructions will influence all interactions with Cline when working on LaTeX documents.

project-specific rules

The key differences in Cline's behavior between source code and LaTeX paper repositories are determined by the .clinerules file and custom instructions. Let me explain the main differences:

Category Source Code Repo LaTeX Paper Repo
File Operations and Patterns - Focuses on code files (*.py, *.cpp, *.js, etc.)- Watches for build artifacts, dependencies (package.json, requirements.txt)- Handles testing files, configuration files- Manages source code organization (src/, tests/, etc.) - Focuses on TeX files (*.tex, *.bib)- Watches for figure files and bibliography- Handles LaTeX-specific auxiliary files (.aux, .log, etc.)- Manages paper section organization
Quality Checks - Code style and formatting- Function/class documentation- Error handling- Test coverage- Performance considerations- Security vulnerabilities - Academic writing style- Citation completeness- Figure/table references- Mathematical notation consistency- Section flow and transitions- Spelling and grammar
Build Process - Compiling/building executables- Running test suites- Package management- Deployment procedures- CI/CD integration - LaTeX compilation (pdflatex/bibtex)- Figure generation/inclusion- Bibliography processing- PDF output generation- Spell checking
Tool Usage - Heavy use of terminal commands for building/testing- Code editing and refactoring tools- Version control operations- Dependency management tools - LaTeX-specific build commands- Figure handling tools- Bibliography management- PDF viewer integration
Content Assistance - Code completion- Algorithm implementation- API usage- Design patterns- Performance optimization - Academic writing style- Technical explanations- Equation formatting- Citation management- Logical flow improvement

example .clonerules

# LaTeX Paper Writing Guidelines for CompilerGPT-CP3O

## Project Structure
- Main paper file: main.tex
- Bibliography: citations.bib
- Section files: 
  - abstract.tex
  - intro.tex
  - bg.tex
  - compgpt.tex
  - eval.tex
  - relwork.tex
  - conclusion.tex
- Supporting files:
  - defs.tex (definitions and macros)
  - figures/ (directory for figures)

## LaTeX Best Practices
- Use consistent notation throughout the paper
- Maintain proper cross-referencing between sections
- Follow consistent citation style
- Use vector graphics in figures/ when possible
- Keep equations and algorithms properly numbered and referenced

## Writing Style Guidelines
- Focus on compiler design, optimization, and AI/ML integration
- Maintain academic tone appropriate for systems/PL venues
- Use precise technical terminology
- Ensure clear transitions between sections
- Support claims with empirical evidence from evaluation

## Build and Compilation
- Use Makefile for building the paper
- Keep intermediate files clean
- Ensure all figures are properly included
- Verify all citations are present in citations.bib

## Quality Checks
- Verify all citations are used and properly formatted
- Check figure/table references
- Ensure consistent terminology across sections
- Validate mathematical notation consistency
- Check for proper section hierarchy and flow

## File Patterns to Watch
- *.tex files for content
- citations.bib for references
- figures/* for diagrams and plots
- Makefile for build instructions