@withpica/mcp-sdk 3.15.0 → 3.16.0

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
@@ -11,6 +11,23 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
11
11
 
12
12
  ## [Unreleased]
13
13
 
14
+ ## [3.16.0] - 2026-09-09
15
+
16
+ ### Added
17
+
18
+ - `works.search()` accepts `has_lyrics` (boolean) and writes it to the query
19
+ string. Without it a caller could not count works holding a lyric sheet
20
+ without paging the whole catalogue, which is how a connector session came to
21
+ inspect one work, see `lyrics: null`, and report that lyrics were not being
22
+ stored for an org holding 178 of them (PICA FIX_LOG 2026-09-09).
23
+
24
+ ⚠️ **`@withpica/mcp-server` must not be published against 3.15.0 once its
25
+ `pica_works_query` declares `has_lyrics`.** `URLSearchParams` drops unknown
26
+ keys silently, so an older SDK would send no filter, the route would return the
27
+ unfiltered catalogue, and the tool description tells the agent to read `total`
28
+ as the answer — it would report every work as having lyrics. Publish this
29
+ package first.
30
+
14
31
  ## [3.15.0] - 2026-09-08
15
32
 
16
33
  ### Added
package/dist/index.d.ts CHANGED
@@ -985,6 +985,11 @@ declare class WorksResource extends BaseResource {
985
985
  has_iswc?: boolean;
986
986
  /** Filter to works that have (true) or lack (false) a publisher_name. */
987
987
  has_publisher?: boolean;
988
+ /**
989
+ * Filter to works that have (true) or lack (false) a stored lyric sheet
990
+ * (works.lyrics; blank counts as lacking).
991
+ */
992
+ has_lyrics?: boolean;
988
993
  }): Promise<PaginatedResult<Work>>;
989
994
  get(id: string): Promise<Work>;
990
995
  create(data: Partial<Work> & {
@@ -1508,6 +1513,31 @@ interface IdentifyResult {
1508
1513
  confidence: number;
1509
1514
  };
1510
1515
  }
1516
+ export interface AudioFileTranscriptSegment {
1517
+ start: number;
1518
+ end: number;
1519
+ text: string;
1520
+ confidence?: number;
1521
+ }
1522
+ export interface AudioFileTranscript {
1523
+ audio_file_id: string;
1524
+ has_transcript: boolean;
1525
+ /** absent when has_transcript is false */
1526
+ work_id?: string | null;
1527
+ recording_id?: string | null;
1528
+ /** false when the transcript reaches no work — nothing else can show it */
1529
+ reaches_work?: boolean;
1530
+ transcript: {
1531
+ full_text: string;
1532
+ language: string | null;
1533
+ confidence: number | null;
1534
+ segment_count: number;
1535
+ segments: AudioFileTranscriptSegment[];
1536
+ processor: string | null;
1537
+ model_version: string | null;
1538
+ created_at: string | null;
1539
+ } | null;
1540
+ }
1511
1541
  declare class AudioFilesResource extends BaseResource {
1512
1542
  list(params?: {
1513
1543
  work_id?: string;
@@ -1519,6 +1549,16 @@ declare class AudioFilesResource extends BaseResource {
1519
1549
  offset?: number;
1520
1550
  }): Promise<AudioFile[]>;
1521
1551
  get(id: string): Promise<AudioFile>;
1552
+ /**
1553
+ * The stored Whisper transcript for one audio file, linked to a work or not.
1554
+ *
1555
+ * Until 2026-09-07 a transcript was readable only as `works.lyrics` after
1556
+ * propagation, so a transcript on an unlinked file had no reader at all —
1557
+ * 218 of 558 on prod. `has_transcript: false` is a normal answer, not an
1558
+ * error, and `reaches_work` says whether this transcript can be seen
1559
+ * anywhere else.
1560
+ */
1561
+ getTranscript(id: string): Promise<AudioFileTranscript>;
1522
1562
  /**
1523
1563
  * Attach ALL orphan audio files whose suggested match is ISRC-high and
1524
1564
  * non-ambiguous, in one call. Pairings are recomputed server-side at