62 lines
1.6 KiB
Markdown
62 lines
1.6 KiB
Markdown
# arubinochan-bot
|
|
|
|
Misskey のタイムラインを読み、ローカル LLM で「あるびのちゃん」として投稿する bot です。
|
|
|
|
To install dependencies:
|
|
|
|
```bash
|
|
bun install
|
|
```
|
|
|
|
To run:
|
|
|
|
```bash
|
|
bun run index.ts
|
|
```
|
|
|
|
Dry run without posting:
|
|
|
|
```bash
|
|
bun run index.ts --test
|
|
```
|
|
|
|
Useful runtime options:
|
|
|
|
```bash
|
|
bun run index.ts --test --harness speaker --politeness auto --sampling creative
|
|
```
|
|
|
|
- `--harness speaker`: default. Starts generation with `あるびのちゃん:\n` and parses the following body.
|
|
- `--harness tagged`: wraps output in a lightweight `<post>` envelope.
|
|
- `--harness json`: legacy JSON grammar harness.
|
|
- `--politeness auto`: default. Rephrases once only when the generated text does not look polite enough.
|
|
- `--politeness always`: always runs the style converter.
|
|
- `--politeness never`: disables style conversion.
|
|
- `--sampling creative`: default. Keeps the more idiosyncratic tone used by the bot.
|
|
- `--sampling model-default`: uses model-card-like sampling parameters for supported models.
|
|
|
|
Environment variables:
|
|
|
|
```env
|
|
MISSKEY_ORIGIN=https://misskey.example.net
|
|
MISSKEY_CREDENTIAL=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
|
|
MODEL="LiquidAI/LFM2-2.6B-GGUF:Q5_K_M"
|
|
HARNESS="speaker"
|
|
POLITENESS="auto"
|
|
SAMPLING="creative"
|
|
```
|
|
|
|
Evaluation without posting:
|
|
|
|
```bash
|
|
bun run evaluate.ts --all-env --candidates --runs 1 --output .evaluation-results.jsonl
|
|
```
|
|
|
|
Resume a crashed/interrupted evaluation:
|
|
|
|
```bash
|
|
bun run evaluate.ts --all-env --candidates --runs 1 --output .evaluation-results.jsonl --resume
|
|
```
|
|
|
|
See [EVALUATION.md](./EVALUATION.md) for the harness/model comparison and the current recommendation.
|