https://github.com/zkfmapf123/llm-word-chain-game
word chain game
https://github.com/zkfmapf123/llm-word-chain-game
fiber go-llm golang llm openai pgvector
Last synced: 7 months ago
JSON representation
word chain game
- Host: GitHub
- URL: https://github.com/zkfmapf123/llm-word-chain-game
- Owner: zkfmapf123
- Created: 2025-03-02T17:01:50.000Z (7 months ago)
- Default Branch: master
- Last Pushed: 2025-03-02T17:14:48.000Z (7 months ago)
- Last Synced: 2025-03-02T18:25:24.082Z (7 months ago)
- Topics: fiber, go-llm, golang, llm, openai, pgvector
- Language: Go
- Homepage:
- Size: 38.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 끝말잇기 LLM
## Run ( use Docker ... )
```sh
// swagger
swag fmt
swag init// execute
make run
or
docker-compose up --build -d
```## API
- http://localhost:3000/swagger
```sh
http://localhost:3000/ping
http://localhost:3000/api/session // 세션 시작
http://localhost:3000/api/play // 끝말잇기 시작
```## PG Table
```sql
CREATE EXTENSION IF NOT EXISTS vector;CREATE TABLE sessions (
id SERIAL PRIMARY KEY,
created_at TIMESTAMP DEFAULT now()
);CREATE TABLE words (
id SERIAL PRIMARY KEY,
session_id INT REFERENCES sessions(id) ON DELETE CASCADE,
word TEXT NOT NULL,
created_at TIMESTAMP DEFAULT NOW(), -- 자동으로 현재 시간 저장
embedding VECTOR(1536), -- OpenAI 임베딩 크기
UNIQUE(session_id, word) -- 같은 세션에서는 중복 불가
);
```## Result
- 0.19 $ 사용 함 ... 비싼듯?
