llm-messages 0.4.4 → 0.4.6

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
@@ -4,6 +4,22 @@ All notable changes to this project are documented here. The format is based on
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and this project adheres
5
5
  to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.4.6] - 2026-06-04
8
+
9
+ ### Added
10
+
11
+ - Added a public conformance fixtures plan describing how API credits should be
12
+ used to refresh deterministic OpenAI/provider conversion fixtures without
13
+ putting secrets in public CI.
14
+
15
+ ## [0.4.5] - 2026-06-04
16
+
17
+ ### Changed
18
+
19
+ - Aligned npm keywords with the GitHub repository topics for OpenAI-compatible
20
+ provider portability, chat completions, multimodal messages and zero
21
+ dependencies.
22
+
7
23
  ## [0.4.4] - 2026-06-04
8
24
 
9
25
  ### Changed
package/README.md CHANGED
@@ -175,7 +175,9 @@ via `dropped-content` rather than failing.
175
175
 
176
176
  See [ROADMAP.md](./ROADMAP.md) for current maintenance priorities, including
177
177
  OpenAI Responses API coverage, live conformance fixtures and tool-call edge
178
- cases.
178
+ cases. The [conformance fixtures plan](./docs/conformance-fixtures.md) describes
179
+ how API credits should be used to refresh deterministic public fixtures without
180
+ putting secrets in CI.
179
181
 
180
182
  ## Provider portability suite
181
183
 
package/ROADMAP.md CHANGED
@@ -20,6 +20,8 @@ fallback behavior matter.
20
20
  payloads, keeping the committed test fixtures deterministic and safe to run
21
21
  without API keys.
22
22
 
23
+ Plan: [docs/conformance-fixtures.md](./docs/conformance-fixtures.md)
24
+
23
25
  3. **Tool-call edge cases**
24
26
 
25
27
  Expand tests for parallel tool calls, missing provider ids, invalid JSON
@@ -0,0 +1,58 @@
1
+ # Conformance fixtures plan
2
+
3
+ `llm-messages` keeps OpenAI Chat Completions-compatible messages as its hub
4
+ shape. Provider-backed conformance fixtures are the next layer for proving that
5
+ the conversions stay correct as OpenAI, Anthropic and Gemini payloads evolve.
6
+
7
+ The fixture workflow should be safe to run in public CI without secrets, while
8
+ still allowing maintainers to refresh source payloads with API credits when
9
+ needed.
10
+
11
+ ## Fixture classes
12
+
13
+ | Class | What it proves |
14
+ | ------------------- | ------------------------------------------------------------------------------ |
15
+ | Text response | Basic assistant text maps into the canonical OpenAI message shape. |
16
+ | Tool call | Provider tool/function calls preserve name, arguments and ids where available. |
17
+ | Tool result | Tool result placement remains valid after provider conversion. |
18
+ | Parallel tools | Multiple tool calls and results keep deterministic ordering. |
19
+ | Multimodal input | Image, audio and document parts are preserved or warned consistently. |
20
+ | Responses API shape | OpenAI Responses API output can be mapped or rejected with explicit warnings. |
21
+ | Lossy conversion | Unsupported or ambiguous provider data emits stable warning codes. |
22
+
23
+ ## Refresh flow
24
+
25
+ 1. Generate provider payloads locally with maintainer-controlled API keys.
26
+ 2. Minimize each payload to the fields needed for conversion coverage.
27
+ 3. Remove request ids, timestamps, account metadata and provider-specific
28
+ tracking fields.
29
+ 4. Commit only deterministic JSON fixtures and expected normalized output.
30
+ 5. Run public CI without any API keys.
31
+
32
+ ## OpenAI API credit use
33
+
34
+ Credits should be used only for fixture refreshes that improve public coverage:
35
+
36
+ - Responses API text and tool-call payloads.
37
+ - Streaming/tool-call examples that differ from Chat Completions.
38
+ - Multimodal message examples relevant to provider conversion.
39
+ - Regression checks before releases when provider payload formats change.
40
+
41
+ Credits should not be used for hidden benchmarks, private app traffic or tests
42
+ that require secrets in public CI.
43
+
44
+ ## Fixture contract
45
+
46
+ Every committed fixture should include:
47
+
48
+ - Provider name and source API family.
49
+ - Input payload.
50
+ - Expected canonical OpenAI-compatible message.
51
+ - Expected provider output when round-tripping is supported.
52
+ - Expected warning codes for lossy or unsupported conversions.
53
+ - A short note explaining why the case matters.
54
+
55
+ ## Public CI rule
56
+
57
+ Public CI must remain offline and deterministic. Live provider calls belong in a
58
+ maintainer-only refresh script, not in the default test suite.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "llm-messages",
3
- "version": "0.4.4",
3
+ "version": "0.4.6",
4
4
  "description": "Convert chat conversations and responses between OpenAI, Anthropic and Gemini. Tool calls, images, audio, documents and roles handled. Zero dependencies.",
5
5
  "keywords": [
6
6
  "openai",
@@ -10,17 +10,25 @@
10
10
  "deepseek",
11
11
  "groq",
12
12
  "openrouter",
13
+ "openai-compatible",
13
14
  "llm",
14
15
  "messages",
15
16
  "chat",
17
+ "chat-completions",
16
18
  "convert",
17
19
  "function-calling",
18
20
  "tool-use",
19
21
  "tool-calls",
20
22
  "provider",
21
23
  "portability",
24
+ "provider-portability",
25
+ "structured-outputs",
26
+ "multimodal",
22
27
  "ai",
23
- "agents"
28
+ "agents",
29
+ "ai-agents",
30
+ "typescript",
31
+ "zero-dependencies"
24
32
  ],
25
33
  "license": "MIT",
26
34
  "author": "Sebastian Legarraga",
@@ -46,6 +54,7 @@
46
54
  },
47
55
  "files": [
48
56
  "dist",
57
+ "docs",
49
58
  "README.md",
50
59
  "ROADMAP.md",
51
60
  "LICENSE",