@agent-media/video 0.1.1
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/dist/actions/index.d.ts +1 -0
- package/dist/actions/index.d.ts.map +1 -0
- package/dist/actions/index.js +4 -0
- package/dist/actions/index.js.map +1 -0
- package/dist/actions/transcribe.d.ts +20 -0
- package/dist/actions/transcribe.d.ts.map +1 -0
- package/dist/actions/transcribe.js +25 -0
- package/dist/actions/transcribe.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -0
- package/package.json +40 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/actions/index.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/actions/index.ts"],"names":[],"mappings":";AAAA,6DAA6D;AAC7D,mDAAmD"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { MediaResult } from '@agent-media/core';
|
|
2
|
+
export interface TranscribeInput {
|
|
3
|
+
/** Input file path or URL */
|
|
4
|
+
input: string;
|
|
5
|
+
/** Enable speaker identification */
|
|
6
|
+
diarize?: boolean;
|
|
7
|
+
/** Language code (auto-detected if not provided) */
|
|
8
|
+
language?: string;
|
|
9
|
+
/** Number of speakers hint */
|
|
10
|
+
numSpeakers?: number;
|
|
11
|
+
/** Output directory (overrides default) */
|
|
12
|
+
out?: string;
|
|
13
|
+
/** Provider to use (overrides auto-detection) */
|
|
14
|
+
provider?: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Transcribe audio/video to text with timestamps
|
|
18
|
+
*/
|
|
19
|
+
export declare function transcribe(options: TranscribeInput): Promise<MediaResult>;
|
|
20
|
+
//# sourceMappingURL=transcribe.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transcribe.d.ts","sourceRoot":"","sources":["../../src/actions/transcribe.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAA6B,MAAM,mBAAmB,CAAC;AAGhF,MAAM,WAAW,eAAe;IAC9B,6BAA6B;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,oCAAoC;IACpC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,oDAAoD;IACpD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,8BAA8B;IAC9B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,2CAA2C;IAC3C,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,iDAAiD;IACjD,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,wBAAsB,UAAU,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAAC,WAAW,CAAC,CA0B/E"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { executeAction, globalRegistry } from '@agent-media/core';
|
|
2
|
+
/**
|
|
3
|
+
* Transcribe audio/video to text with timestamps
|
|
4
|
+
*/
|
|
5
|
+
export async function transcribe(options) {
|
|
6
|
+
const isUrl = options.input.startsWith('http://') || options.input.startsWith('https://');
|
|
7
|
+
const input = {
|
|
8
|
+
source: options.input,
|
|
9
|
+
isUrl,
|
|
10
|
+
};
|
|
11
|
+
const context = {
|
|
12
|
+
outputDir: options.out ?? process.cwd() + '/.agent-media',
|
|
13
|
+
provider: options.provider,
|
|
14
|
+
};
|
|
15
|
+
return executeAction(globalRegistry, {
|
|
16
|
+
action: 'transcribe',
|
|
17
|
+
options: {
|
|
18
|
+
input,
|
|
19
|
+
diarize: options.diarize,
|
|
20
|
+
language: options.language,
|
|
21
|
+
numSpeakers: options.numSpeakers,
|
|
22
|
+
},
|
|
23
|
+
}, context);
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=transcribe.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"transcribe.js","sourceRoot":"","sources":["../../src/actions/transcribe.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAiBlE;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,UAAU,CAAC,OAAwB;IACvD,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,SAAS,CAAC,IAAI,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,CAAC;IAE1F,MAAM,KAAK,GAAe;QACxB,MAAM,EAAE,OAAO,CAAC,KAAK;QACrB,KAAK;KACN,CAAC;IAEF,MAAM,OAAO,GAAkB;QAC7B,SAAS,EAAE,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,EAAE,GAAG,eAAe;QACzD,QAAQ,EAAE,OAAO,CAAC,QAAQ;KAC3B,CAAC;IAEF,OAAO,aAAa,CAClB,cAAc,EACd;QACE,MAAM,EAAE,YAAY;QACpB,OAAO,EAAE;YACP,KAAK;YACL,OAAO,EAAE,OAAO,CAAC,OAAO;YACxB,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,WAAW,EAAE,OAAO,CAAC,WAAW;SACjC;KACF,EACD,OAAO,CACR,CAAC;AACJ,CAAC"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,YAAY,EACV,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,6DAA6D;AAC7D,mDAAmD;AAOnD,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@agent-media/video",
|
|
3
|
+
"version": "0.1.1",
|
|
4
|
+
"description": "Video actions for agent-media toolkit",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/TimPietrusky/agent-media.git",
|
|
9
|
+
"directory": "packages/video"
|
|
10
|
+
},
|
|
11
|
+
"type": "module",
|
|
12
|
+
"main": "./dist/index.js",
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
|
+
"exports": {
|
|
15
|
+
".": {
|
|
16
|
+
"types": "./dist/index.d.ts",
|
|
17
|
+
"import": "./dist/index.js"
|
|
18
|
+
},
|
|
19
|
+
"./actions": {
|
|
20
|
+
"types": "./dist/actions/index.d.ts",
|
|
21
|
+
"import": "./dist/actions/index.js"
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"files": [
|
|
25
|
+
"dist"
|
|
26
|
+
],
|
|
27
|
+
"scripts": {
|
|
28
|
+
"build": "tsc",
|
|
29
|
+
"clean": "rm -rf dist",
|
|
30
|
+
"typecheck": "tsc --noEmit"
|
|
31
|
+
},
|
|
32
|
+
"dependencies": {
|
|
33
|
+
"@agent-media/core": "workspace:*",
|
|
34
|
+
"@agent-media/providers": "workspace:*"
|
|
35
|
+
},
|
|
36
|
+
"devDependencies": {
|
|
37
|
+
"@types/node": "^22.0.0",
|
|
38
|
+
"typescript": "^5.7.0"
|
|
39
|
+
}
|
|
40
|
+
}
|