yangrongzhao
Inflect-Micro-v2 TTS: AX650 NPU3, U16 AXMODEL
7cbe545
|
Raw
History Blame Contribute Delete
1.15 kB

Inflect-Micro-v2 C++ SDK for AX650

Build

export AX_RUNTIME_ROOT=/path/to/ax650_bsp
mkdir build && cd build
cmake .. && make

Produces:

  • libinflect_tts.a — TTS engine library
  • tts_cli — Command-line TTS tool
  • tts_server — OpenAI-compatible HTTP server

CLI

./tts_cli --text "Hello world" --output speech.wav
./tts_cli --text "Faster speech" --speed 1.5 --output fast.wav

HTTP Server (OpenAI-compatible)

./tts_server --port 8000
# Test
curl -X POST http://localhost:8000/v1/audio/speech \
  -H "Content-Type: application/json" \
  -d '{"model":"tts-1","input":"Hello world"}' \
  --output speech.wav

For full HTTP support, install cpp-httplib and nlohmann/json, uncomment USE_CPPHTTPLIB in CMakeLists.txt.

API

Endpoint Method Description
/health GET Health check
/v1/models GET List models
/v1/audio/speech POST OpenAI TTS API

Request body for /v1/audio/speech:

{
  "model": "tts-1",
  "input": "Hello world",
  "voice": "default",
  "speed": 1.0,
  "response_format": "wav"
}