namu-ai 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,15 @@
1
1
  # Changelog
2
2
 
3
- ## 0.1.0 (unreleased)
3
+ ## 0.1.2 (29 November 2026)
4
+
5
+ `converse` takes `language`: the language the person speaks and the agent answers in (Hausa when not given; also
6
+ Zarma, Fulfulde, Kanuri and Tamasheq). `ConverseTurn` gains `language`.
7
+
8
+ ## 0.1.1 (27 November 2026)
9
+
10
+ The README's Data section now says only what Namu keeps: usage records, not your audio or text. No code changes.
11
+
12
+ ## 0.1.0 (8 November 2026)
4
13
 
5
14
  First version: `Namu` with `speech`, `transcribe`, `translate`, `converse`, `usage`, `voices` and `models`; types for
6
15
  every response; one error class per status; retries for network errors, `rate_limited` and 502/503/504; timeouts; the
package/README.md CHANGED
@@ -38,6 +38,7 @@ const spoken = await namu.translate({ audio: await readFile("question.ogg") }, {
38
38
 
39
39
  // Voice agent (research preview; the key needs the converse scope)
40
40
  const turn = await namu.converse(await readFile("hello.ogg"), { sessionId: "demo-42" });
41
+ const fulfulde = await namu.converse(await readFile("sannu.ogg"), { persona: "mouhamad", language: "ff" }); // also ha, dje, kr, tmh
41
42
 
42
43
  // Account and catalogue
43
44
  await namu.usage(); // { month_audio_seconds_used, month_audio_seconds_limit }
@@ -94,9 +95,7 @@ const namu = new Namu({ timeoutMs: 120_000, maxRetries: 5 });
94
95
 
95
96
  ## Data
96
97
 
97
- Speech to text and text to speech run on Namu's own models. Translation and the voice agent's replies are written by
98
- Google Gemini through OpenRouter, which receives the text they work on. Namu keeps usage records, not your audio or
99
- text.
98
+ Namu keeps usage records, not your audio or text.
100
99
 
101
100
  ## Development
102
101
 
package/dist/client.d.ts CHANGED
@@ -46,10 +46,13 @@ export declare class Namu {
46
46
  source?: "ha" | "fr";
47
47
  includeAudio?: boolean;
48
48
  }): Promise<Translation>;
49
- /** One turn with the voice agent, in Hausa (research preview; the key needs the converse scope). */
49
+ /** One turn with the voice agent (research preview; the key needs the converse scope). `language` is the language the
50
+ person speaks and the agent answers in: Hausa ("ha") when not given, or "dje", "ff", "kr", "tmh" (models() lists
51
+ them); the persona "mouhamad" speaks them all, "nadia" Hausa only. */
50
52
  converse(audio: AudioInput, opts?: {
51
53
  sessionId?: string;
52
54
  persona?: string;
55
+ language?: string;
53
56
  }): Promise<ConverseTurn>;
54
57
  /** Audio seconds used this calendar month (UTC) and the allowance. Free: counts nothing. */
55
58
  usage(): Promise<Usage>;
package/dist/client.js CHANGED
@@ -47,9 +47,11 @@ export class Namu {
47
47
  }
48
48
  return (await this.#request("POST", "/v1/translate", { form: { file: input.audio, target, source: opts.source, include_audio: opts.includeAudio ? "true" : undefined } })).json();
49
49
  }
50
- /** One turn with the voice agent, in Hausa (research preview; the key needs the converse scope). */
50
+ /** One turn with the voice agent (research preview; the key needs the converse scope). `language` is the language the
51
+ person speaks and the agent answers in: Hausa ("ha") when not given, or "dje", "ff", "kr", "tmh" (models() lists
52
+ them); the persona "mouhamad" speaks them all, "nadia" Hausa only. */
51
53
  async converse(audio, opts = {}) {
52
- return (await this.#request("POST", "/v1/converse", { form: { file: audio, persona: opts.persona ?? "nadia", session_id: opts.sessionId } })).json();
54
+ return (await this.#request("POST", "/v1/converse", { form: { file: audio, persona: opts.persona ?? "nadia", language: opts.language, session_id: opts.sessionId } })).json();
53
55
  }
54
56
  /** Audio seconds used this calendar month (UTC) and the allowance. Free: counts nothing. */
55
57
  async usage() {
package/dist/types.d.ts CHANGED
@@ -31,6 +31,8 @@ export interface Translation {
31
31
  export interface ConverseTurn {
32
32
  model: string;
33
33
  persona: string;
34
+ /** The language of the turn: what the person spoke and the agent answered in. */
35
+ language: string;
34
36
  session_id: string | null;
35
37
  /** What the person said, as text. */
36
38
  heard: string;
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const VERSION = "0.1.0";
1
+ export declare const VERSION = "0.1.2";
package/dist/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = "0.1.0";
1
+ export const VERSION = "0.1.2";
package/package.json CHANGED
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "name": "namu-ai",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "The Namu API for JavaScript and TypeScript: speech recognition, speech synthesis and translation for Hausa, Zarma and French.",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Namu AI Lab <contact@namuai.org>",
7
7
  "homepage": "https://www.namuai-lab.com/api",
8
+ "repository": { "type": "git", "url": "git+https://github.com/namu-ai-lab/namu-sdks.git", "directory": "typescript" },
8
9
  "keywords": ["namu", "speech", "text-to-speech", "speech-to-text", "translation", "hausa", "zarma", "french", "sahel"],
9
10
  "type": "module",
10
11
  "exports": {