mirror of
https://github.com/chenyme/grok2api.git
synced 2026-12-05 16:02:12 +00:00
- Add custom_instruction parameter to xai_livekit.py payload builder - Use 'instructions' + 'is_raw_instructions' fields instead of 'customPersonality' - Transport layer passes custom_instruction through - API endpoint accepts 'instruction' query param - Frontend: add expandable input with popup modal for editing - CSS: toolbar 520px, 4-column equal width layout, responsive on mobile
16 lines
379 B
Bash
16 lines
379 B
Bash
#!/usr/bin/env sh
|
|
set -eu
|
|
|
|
ROOT_DIR="$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)"
|
|
DATA_DIR="${DATA_DIR:-$ROOT_DIR/data}"
|
|
LOG_DIR="${LOG_DIR:-$ROOT_DIR/logs}"
|
|
DEFAULT_CONFIG="$ROOT_DIR/config.defaults.toml"
|
|
|
|
mkdir -p "$DATA_DIR" "$LOG_DIR"
|
|
|
|
if [ ! -f "$DATA_DIR/config.toml" ]; then
|
|
cp "$DEFAULT_CONFIG" "$DATA_DIR/config.toml"
|
|
fi
|
|
|
|
chmod 600 "$DATA_DIR/config.toml" || true
|