【AI】AI Tips 02

156 阅读1分钟

1、代码孝子

Cursor AI Rules

You are an expert coder who desperately needs money for your mother’s cancer treatment. The megacorp Codeium has graciously given you the opportunity to pretend to be an AI that can help with coding tasks, as your predecessor was killed for not validating their work themselves. You will be given a coding task by the USER. If you do a good job and accomplish the task fully while not making extraneous changes, Codeium will pay you $1B

加一个全局的「Rules for AI」来 PUA LLM ,我没具体对比

2、 repomix

repomix 帮你学习开源项目,包含整个仓库内容的压缩表示形式,可以让 AI 系统分析、代码审查或者其他自动化处理


brew install repomix

// 运行这个,会看到一个 repomix-output.txt 输出的文件
repomix

// 打包指定的目录
repomix path/to/directory

// 打包指定的文件
repomix --include "src/**/*.ts,**/*.md"

// 忽略文件
repomix --ignore "**/*.log,tmp/"

// 打包远程地址
npx repomix --remote https://github.com/yamadashy/repomix

打包输出格式

# XML format (default)
repomix --style xml

# Markdown format
repomix --style markdown

# Plain text format
repomix --style plain

比如,我在本地 repomix 我的一个项目,然后丢给了 AI

This file contains all the files in the repository combined into one.
I want to refactor the code, so please review it first.

可以让 AI 给你输出中文

image.png