phenoml 11.1.0 → 11.3.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.
Files changed (25) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/authtoken/resources/auth/client/requests/AuthGenerateTokenRequest.d.ts +2 -2
  3. package/dist/cjs/api/resources/construe/types/ExtractRequestConfig.d.ts +15 -1
  4. package/dist/cjs/api/resources/construe/types/ExtractRequestConfig.js +1 -0
  5. package/dist/cjs/api/resources/fhirProvider/types/AuthMethod.d.ts +2 -1
  6. package/dist/cjs/api/resources/fhirProvider/types/AuthMethod.js +2 -1
  7. package/dist/cjs/api/resources/fhirProvider/types/Provider.d.ts +1 -0
  8. package/dist/cjs/api/resources/fhirProvider/types/Provider.js +1 -0
  9. package/dist/cjs/api/resources/fhirProvider/types/Role.d.ts +2 -2
  10. package/dist/cjs/api/resources/fhirProvider/types/Role.js +2 -2
  11. package/dist/cjs/version.d.ts +1 -1
  12. package/dist/cjs/version.js +1 -1
  13. package/dist/esm/BaseClient.mjs +2 -2
  14. package/dist/esm/api/resources/authtoken/resources/auth/client/requests/AuthGenerateTokenRequest.d.mts +2 -2
  15. package/dist/esm/api/resources/construe/types/ExtractRequestConfig.d.mts +15 -1
  16. package/dist/esm/api/resources/construe/types/ExtractRequestConfig.mjs +1 -0
  17. package/dist/esm/api/resources/fhirProvider/types/AuthMethod.d.mts +2 -1
  18. package/dist/esm/api/resources/fhirProvider/types/AuthMethod.mjs +2 -1
  19. package/dist/esm/api/resources/fhirProvider/types/Provider.d.mts +1 -0
  20. package/dist/esm/api/resources/fhirProvider/types/Provider.mjs +1 -0
  21. package/dist/esm/api/resources/fhirProvider/types/Role.d.mts +2 -2
  22. package/dist/esm/api/resources/fhirProvider/types/Role.mjs +2 -2
  23. package/dist/esm/version.d.mts +1 -1
  24. package/dist/esm/version.mjs +1 -1
  25. package/package.json +1 -1
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
43
43
  const headers = (0, headers_js_1.mergeHeaders)({
44
44
  "X-Fern-Language": "JavaScript",
45
45
  "X-Fern-SDK-Name": "phenoml",
46
- "X-Fern-SDK-Version": "11.1.0",
47
- "User-Agent": "phenoml/11.1.0",
46
+ "X-Fern-SDK-Version": "11.3.0",
47
+ "User-Agent": "phenoml/11.3.0",
48
48
  "X-Fern-Runtime": core.RUNTIME.type,
49
49
  "X-Fern-Runtime-Version": core.RUNTIME.version,
50
50
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -6,8 +6,8 @@
6
6
  * }
7
7
  */
8
8
  export interface AuthGenerateTokenRequest {
9
- /** The user's username or email */
9
+ /** The API credential client ID */
10
10
  username: string;
11
- /** The user's password */
11
+ /** The API credential client secret */
12
12
  password: string;
13
13
  }
@@ -28,9 +28,22 @@ export interface ExtractRequestConfig {
28
28
  * Citations show the exact text spans (with character offsets) that led to each code.
29
29
  * Only available when using chunking_method: "sentences".
30
30
  * The "none" method returns full text as one chunk (not useful for citations).
31
- * LLM-based chunking (paragraphs, topics) does not support citations.
31
+ * LLM-based chunking (paragraphs, topics, soap_note) does not support citations.
32
32
  */
33
33
  include_citations?: boolean | undefined;
34
+ /**
35
+ * Optional context describing the goal of the extraction.
36
+ * Required when min_context_relevance is greater than 0.
37
+ */
38
+ extraction_context?: string | undefined;
39
+ /**
40
+ * Minimum relevance score (0.0–1.0) a chunk must reach to proceed to code extraction.
41
+ * Chunks are scored by an LLM against the extraction_context goal. Chunks below this
42
+ * threshold are dropped, reducing noise and extraction cost.
43
+ * Set to 0 (the default) to disable relevance filtering and extract from all chunks.
44
+ * Requires the "extraction_context" field when set above 0.
45
+ */
46
+ min_context_relevance?: number | undefined;
34
47
  }
35
48
  export declare namespace ExtractRequestConfig {
36
49
  /** Method for splitting input text into chunks before code extraction */
@@ -39,6 +52,7 @@ export declare namespace ExtractRequestConfig {
39
52
  readonly Sentences: "sentences";
40
53
  readonly Paragraphs: "paragraphs";
41
54
  readonly Topics: "topics";
55
+ readonly SoapNote: "soap_note";
42
56
  };
43
57
  type ChunkingMethod = (typeof ChunkingMethod)[keyof typeof ChunkingMethod];
44
58
  /**
@@ -10,6 +10,7 @@ var ExtractRequestConfig;
10
10
  Sentences: "sentences",
11
11
  Paragraphs: "paragraphs",
12
12
  Topics: "topics",
13
+ SoapNote: "soap_note",
13
14
  };
14
15
  /**
15
16
  * Method for validating extracted codes:
@@ -11,7 +11,8 @@
11
11
  * return an error.
12
12
  * - `token_passthrough`: The caller provides their own bearer token via the X-Phenoml-Fhir-Provider header
13
13
  * as one or more comma-separated {fhir_provider_id}:{oauth2_token} pairs. Specifying `role` or `scopes`
14
- * will return an error.
14
+ * will return an error. This is the recommended mode for providers like Meditech where the bearer token
15
+ * is typically obtained outside PhenoML.
15
16
  * - `none`: No authentication is performed. Specifying `role` or `scopes` will return an error.
16
17
  *
17
18
  * For the `on_behalf_of` authentication method, you must also provide the Patient or Practitioner reference
@@ -15,7 +15,8 @@ exports.AuthMethod = void 0;
15
15
  * return an error.
16
16
  * - `token_passthrough`: The caller provides their own bearer token via the X-Phenoml-Fhir-Provider header
17
17
  * as one or more comma-separated {fhir_provider_id}:{oauth2_token} pairs. Specifying `role` or `scopes`
18
- * will return an error.
18
+ * will return an error. This is the recommended mode for providers like Meditech where the bearer token
19
+ * is typically obtained outside PhenoML.
19
20
  * - `none`: No authentication is performed. Specifying `role` or `scopes` will return an error.
20
21
  *
21
22
  * For the `on_behalf_of` authentication method, you must also provide the Patient or Practitioner reference
@@ -12,6 +12,7 @@ export declare const Provider: {
12
12
  readonly Epic: "epic";
13
13
  readonly GoogleHealthcare: "google_healthcare";
14
14
  readonly Hapi: "hapi";
15
+ readonly Meditech: "meditech";
15
16
  readonly Medplum: "medplum";
16
17
  readonly Phenostore: "phenostore";
17
18
  readonly Sandbox: "sandbox";
@@ -16,6 +16,7 @@ exports.Provider = {
16
16
  Epic: "epic",
17
17
  GoogleHealthcare: "google_healthcare",
18
18
  Hapi: "hapi",
19
+ Meditech: "meditech",
19
20
  Medplum: "medplum",
20
21
  Phenostore: "phenostore",
21
22
  Sandbox: "sandbox",
@@ -27,8 +27,8 @@
27
27
  * field to specify exact scopes instead.
28
28
  *
29
29
  * Canvas does not support system-level roles — use `scopes` directly.
30
- * Google Healthcare, HAPI, and `none`/`token_passthrough` auth methods
31
- * do not use scopes at all.
30
+ * Google Healthcare, HAPI, Meditech, and `none`/`token_passthrough`
31
+ * auth methods do not use scopes at all.
32
32
  */
33
33
  export declare const Role: {
34
34
  readonly Admin: "admin";
@@ -31,8 +31,8 @@ exports.Role = void 0;
31
31
  * field to specify exact scopes instead.
32
32
  *
33
33
  * Canvas does not support system-level roles — use `scopes` directly.
34
- * Google Healthcare, HAPI, and `none`/`token_passthrough` auth methods
35
- * do not use scopes at all.
34
+ * Google Healthcare, HAPI, Meditech, and `none`/`token_passthrough`
35
+ * auth methods do not use scopes at all.
36
36
  */
37
37
  exports.Role = {
38
38
  Admin: "admin",
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "11.1.0";
1
+ export declare const SDK_VERSION = "11.3.0";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "11.1.0";
4
+ exports.SDK_VERSION = "11.3.0";
@@ -6,8 +6,8 @@ export function normalizeClientOptions(options) {
6
6
  const headers = mergeHeaders({
7
7
  "X-Fern-Language": "JavaScript",
8
8
  "X-Fern-SDK-Name": "phenoml",
9
- "X-Fern-SDK-Version": "11.1.0",
10
- "User-Agent": "phenoml/11.1.0",
9
+ "X-Fern-SDK-Version": "11.3.0",
10
+ "User-Agent": "phenoml/11.3.0",
11
11
  "X-Fern-Runtime": core.RUNTIME.type,
12
12
  "X-Fern-Runtime-Version": core.RUNTIME.version,
13
13
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -6,8 +6,8 @@
6
6
  * }
7
7
  */
8
8
  export interface AuthGenerateTokenRequest {
9
- /** The user's username or email */
9
+ /** The API credential client ID */
10
10
  username: string;
11
- /** The user's password */
11
+ /** The API credential client secret */
12
12
  password: string;
13
13
  }
@@ -28,9 +28,22 @@ export interface ExtractRequestConfig {
28
28
  * Citations show the exact text spans (with character offsets) that led to each code.
29
29
  * Only available when using chunking_method: "sentences".
30
30
  * The "none" method returns full text as one chunk (not useful for citations).
31
- * LLM-based chunking (paragraphs, topics) does not support citations.
31
+ * LLM-based chunking (paragraphs, topics, soap_note) does not support citations.
32
32
  */
33
33
  include_citations?: boolean | undefined;
34
+ /**
35
+ * Optional context describing the goal of the extraction.
36
+ * Required when min_context_relevance is greater than 0.
37
+ */
38
+ extraction_context?: string | undefined;
39
+ /**
40
+ * Minimum relevance score (0.0–1.0) a chunk must reach to proceed to code extraction.
41
+ * Chunks are scored by an LLM against the extraction_context goal. Chunks below this
42
+ * threshold are dropped, reducing noise and extraction cost.
43
+ * Set to 0 (the default) to disable relevance filtering and extract from all chunks.
44
+ * Requires the "extraction_context" field when set above 0.
45
+ */
46
+ min_context_relevance?: number | undefined;
34
47
  }
35
48
  export declare namespace ExtractRequestConfig {
36
49
  /** Method for splitting input text into chunks before code extraction */
@@ -39,6 +52,7 @@ export declare namespace ExtractRequestConfig {
39
52
  readonly Sentences: "sentences";
40
53
  readonly Paragraphs: "paragraphs";
41
54
  readonly Topics: "topics";
55
+ readonly SoapNote: "soap_note";
42
56
  };
43
57
  type ChunkingMethod = (typeof ChunkingMethod)[keyof typeof ChunkingMethod];
44
58
  /**
@@ -7,6 +7,7 @@ export var ExtractRequestConfig;
7
7
  Sentences: "sentences",
8
8
  Paragraphs: "paragraphs",
9
9
  Topics: "topics",
10
+ SoapNote: "soap_note",
10
11
  };
11
12
  /**
12
13
  * Method for validating extracted codes:
@@ -11,7 +11,8 @@
11
11
  * return an error.
12
12
  * - `token_passthrough`: The caller provides their own bearer token via the X-Phenoml-Fhir-Provider header
13
13
  * as one or more comma-separated {fhir_provider_id}:{oauth2_token} pairs. Specifying `role` or `scopes`
14
- * will return an error.
14
+ * will return an error. This is the recommended mode for providers like Meditech where the bearer token
15
+ * is typically obtained outside PhenoML.
15
16
  * - `none`: No authentication is performed. Specifying `role` or `scopes` will return an error.
16
17
  *
17
18
  * For the `on_behalf_of` authentication method, you must also provide the Patient or Practitioner reference
@@ -12,7 +12,8 @@
12
12
  * return an error.
13
13
  * - `token_passthrough`: The caller provides their own bearer token via the X-Phenoml-Fhir-Provider header
14
14
  * as one or more comma-separated {fhir_provider_id}:{oauth2_token} pairs. Specifying `role` or `scopes`
15
- * will return an error.
15
+ * will return an error. This is the recommended mode for providers like Meditech where the bearer token
16
+ * is typically obtained outside PhenoML.
16
17
  * - `none`: No authentication is performed. Specifying `role` or `scopes` will return an error.
17
18
  *
18
19
  * For the `on_behalf_of` authentication method, you must also provide the Patient or Practitioner reference
@@ -12,6 +12,7 @@ export declare const Provider: {
12
12
  readonly Epic: "epic";
13
13
  readonly GoogleHealthcare: "google_healthcare";
14
14
  readonly Hapi: "hapi";
15
+ readonly Meditech: "meditech";
15
16
  readonly Medplum: "medplum";
16
17
  readonly Phenostore: "phenostore";
17
18
  readonly Sandbox: "sandbox";
@@ -13,6 +13,7 @@ export const Provider = {
13
13
  Epic: "epic",
14
14
  GoogleHealthcare: "google_healthcare",
15
15
  Hapi: "hapi",
16
+ Meditech: "meditech",
16
17
  Medplum: "medplum",
17
18
  Phenostore: "phenostore",
18
19
  Sandbox: "sandbox",
@@ -27,8 +27,8 @@
27
27
  * field to specify exact scopes instead.
28
28
  *
29
29
  * Canvas does not support system-level roles — use `scopes` directly.
30
- * Google Healthcare, HAPI, and `none`/`token_passthrough` auth methods
31
- * do not use scopes at all.
30
+ * Google Healthcare, HAPI, Meditech, and `none`/`token_passthrough`
31
+ * auth methods do not use scopes at all.
32
32
  */
33
33
  export declare const Role: {
34
34
  readonly Admin: "admin";
@@ -28,8 +28,8 @@
28
28
  * field to specify exact scopes instead.
29
29
  *
30
30
  * Canvas does not support system-level roles — use `scopes` directly.
31
- * Google Healthcare, HAPI, and `none`/`token_passthrough` auth methods
32
- * do not use scopes at all.
31
+ * Google Healthcare, HAPI, Meditech, and `none`/`token_passthrough`
32
+ * auth methods do not use scopes at all.
33
33
  */
34
34
  export const Role = {
35
35
  Admin: "admin",
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "11.1.0";
1
+ export declare const SDK_VERSION = "11.3.0";
@@ -1 +1 @@
1
- export const SDK_VERSION = "11.1.0";
1
+ export const SDK_VERSION = "11.3.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "phenoml",
3
- "version": "11.1.0",
3
+ "version": "11.3.0",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",