Skip to content

Commit 0af79d3

Browse files
authored
Merge pull request #10 from AssemblyAI/4993FAF28FFD402259A9E17791C0363A
Sync latest
2 parents a372926 + b48d5eb commit 0af79d3

File tree

3 files changed

+13
-8
lines changed

3 files changed

+13
-8
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ const service = client.realtime.createService({
173173
You can also generate a temporary auth token for real-time.
174174

175175
```typescript
176-
const token = await client.realtime.createTemporaryToken({expires_in = 60});
176+
const token = await client.realtime.createTemporaryToken({ expires_in = 60 });
177177
const rt = client.realtime.createService({
178178
token: token
179179
});
@@ -212,7 +212,7 @@ getAudio((chunk) => {
212212
Close the connection when you're finished.
213213

214214
```typescript
215-
rt.close();
215+
await rt.close();
216216
```
217217

218218
# Tests

package.json

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"url": "git+https://github.com/AssemblyAI/assemblyai-node-sdk.git"
1212
},
1313
"publishConfig": {
14-
"tag": "beta",
14+
"tag": "latest",
1515
"access": "public",
1616
"registry": "https://registry.npmjs.org/"
1717
},
@@ -21,12 +21,17 @@
2121
"lint": "tslint -p tsconfig.json",
2222
"test": "pnpm lint && pnpm test:unit",
2323
"test:unit": "jest --config jest.config.rollup.ts",
24-
"prettier": "prettier --write 'src/**/*.ts'",
25-
"generate-types": "tsx ./scripts/generate-types.ts && pnpm prettier"
24+
"format": "prettier --write 'src/**/*.ts'",
25+
"generate-types": "tsx ./scripts/generate-types.ts && pnpm format",
26+
"copybara:dry-run": "./copybara.sh dry_run --init-history",
27+
"copybara:pr": "./copybara.sh sync_out --init-history"
2628
},
2729
"keywords": [
2830
"AssemblyAI",
29-
"Speech-to-text"
31+
"Speech-to-text",
32+
"Transcription",
33+
"Audio",
34+
"LLM"
3035
],
3136
"author": "AssemblyAI (https://www.assemblyai.com)",
3237
"license": "MIT",

scripts/kitchensink.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ const client = new AssemblyAI({
1010
(async function transcribeUsingRealtime() {
1111
const useToken = false;
1212
const serviceParams: any = {
13-
sample_rate: 16_000,
14-
word_boost: ['gore', 'climate']
13+
sampleRate: 16_000,
14+
wordBoost: ['gore', 'climate']
1515
};
1616
if (useToken) {
1717
serviceParams.token = await client.realtime.createTemporaryToken({ expires_in: 480 });

0 commit comments

Comments
 (0)