Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ttttonyhe/openai-sentence-generator
Generate & Templatize Random (Simplified Chinese) Sentences from a List of Attributes using OpenAI
https://github.com/ttttonyhe/openai-sentence-generator
chatgpt-api
Last synced: about 2 months ago
JSON representation
Generate & Templatize Random (Simplified Chinese) Sentences from a List of Attributes using OpenAI
- Host: GitHub
- URL: https://github.com/ttttonyhe/openai-sentence-generator
- Owner: ttttonyhe
- Created: 2024-01-05T15:26:18.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2024-02-26T21:45:39.000Z (10 months ago)
- Last Synced: 2024-05-02T04:13:27.763Z (8 months ago)
- Topics: chatgpt-api
- Language: Python
- Homepage:
- Size: 5.17 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SkyJSON
## 可执行文件
- `gen_file.py`:
- 使用给定的模板句子生成不同类型的 Human-bot 问答对
- `generate_sentences.py`:
- 使用 OpenAI API 使用给定的属性列表生成并模板化包含 5-10 个随机属性的句子 (long-running)
- `generate_progress.py`
- 汇报当前句子生成进度:属性利用量
## 前置数据要求
\* 必须项:
- `gen_file.py`
- \* data/sentences.txt
- data/property_aliases.xlsx
- data/text2json_templates.xlsx
- data/json2json_templates.xlsx
- data/text2table_templates.xlsx
- `generate_sentences.py`
- \* data/properties.xlsx
## 环境变量
在 `constants.py` 里进行配置:
- `VERBOSE`: 是否打印详细数据
- `DEBUGGING`: 是否打印过程数据
- `USE_PROPERTY_ALIASES`: 是否在问答中使用属性别名
## 其他
- `gen_text_tpl.py`:
- 生成 Human 提问时使用的属性列表模板
- `generate_value.py`
- 使用 Faker 或 OpenAI API 为一属性生成合适的随机值