@model-match/api 3.80.1 → 3.82.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/RELEASE_NOTES.md +28 -0
- package/dist/{index-uHovaz1c.d.mts → index-CgMbNPzN.d.mts} +479 -29
- package/dist/index.d.mts +2 -2
- package/dist/index.mjs +1 -1
- package/dist/slim/index.d.mts +17 -5
- package/dist/slim/index.mjs +41 -5
- package/dist/{src-c-fp5gD8.mjs → src-BY9XwetN.mjs} +43 -3
- package/openapi.json +1134 -161
- package/package.json +1 -1
package/dist/slim/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as createClient, w as client } from "../src-
|
|
1
|
+
import { n as createClient, w as client } from "../src-BY9XwetN.mjs";
|
|
2
2
|
//#region src/slim/sdk.gen.ts
|
|
3
3
|
/**
|
|
4
4
|
* Search agents with filters
|
|
@@ -6433,7 +6433,7 @@ const listStudioJobs = (options) => (options?.client ?? client).get({
|
|
|
6433
6433
|
/**
|
|
6434
6434
|
* Save a question as a job
|
|
6435
6435
|
*
|
|
6436
|
-
* Save a SQL question to run again: on a schedule (`daily`, `weekly`) or only when asked (`manual`). Each run stores its result as a table named after the job, which later questions — and later jobs — can query like any other table. Name the `keys` (the columns that identify one row) to get 'what changed since the last run', and add `alerts` to flag new rows, removed rows or a number crossing a threshold. The SQL is checked when the job is saved: an unknown table or column, or a key that is not in the result, is refused here rather than at the first run. Saving does not run the job. Saving is free; each run that succeeds costs 10 credits, including the runs a `daily` or `weekly` schedule starts.
|
|
6436
|
+
* Save a SQL question to run again: on a schedule (`daily`, `weekly`) or only when asked (`manual`). Each run stores its result as a table named after the job, which later questions — and later jobs — can query like any other table. Name the `keys` (the columns that identify one row) to get 'what changed since the last run', and add `alerts` to flag new rows, removed rows or a number crossing a threshold. When an alert matches on a scheduled run, the job's creator is emailed (once per hourly tick, every job of theirs in one email, also in their notifications); `notify: { email: false }` saves the job without those emails, and `updateStudioJob` changes it later. Webhooks are not available yet. The SQL is checked when the job is saved: an unknown table or column, or a key that is not in the result, is refused here rather than at the first run. Saving does not run the job. Saving is free; each run that succeeds costs 10 credits, including the runs a `daily` or `weekly` schedule starts.
|
|
6437
6437
|
*/
|
|
6438
6438
|
const createStudioJob = (options) => (options.client ?? client).post({
|
|
6439
6439
|
security: [{
|
|
@@ -6483,6 +6483,26 @@ const getStudioJob = (options) => (options.client ?? client).get({
|
|
|
6483
6483
|
...options
|
|
6484
6484
|
});
|
|
6485
6485
|
/**
|
|
6486
|
+
* Change a job's settings
|
|
6487
|
+
*
|
|
6488
|
+
* Change how a saved job tells you about its alerts: `notify.email` false stops the email to the job's creator when an alert matches on a scheduled run; true turns it back on. Matched alerts are still recorded on each run. Free.
|
|
6489
|
+
*/
|
|
6490
|
+
const updateStudioJob = (options) => (options.client ?? client).patch({
|
|
6491
|
+
security: [{
|
|
6492
|
+
name: "x-api-key",
|
|
6493
|
+
type: "apiKey"
|
|
6494
|
+
}, {
|
|
6495
|
+
scheme: "bearer",
|
|
6496
|
+
type: "http"
|
|
6497
|
+
}],
|
|
6498
|
+
url: "/v1/studio/jobs/{name}",
|
|
6499
|
+
...options,
|
|
6500
|
+
headers: {
|
|
6501
|
+
"Content-Type": "application/json",
|
|
6502
|
+
...options.headers
|
|
6503
|
+
}
|
|
6504
|
+
});
|
|
6505
|
+
/**
|
|
6486
6506
|
* Run a job now
|
|
6487
6507
|
*
|
|
6488
6508
|
* Run a saved job now. Answers `200` with the finished run (its row count, what changed and any alerts) when it ends within a few seconds; otherwise `202` with `status: running`, and the run carries on — read the job to see how it ended. A run that fails answers `422` with `code: job_failed` and the reason. One job runs at a time per organization. 10 credits for a run that succeeds; a failed run is free. A run that has succeeded by the time this returns is charged now (`credits.charged`, with `credits.remaining`). One still running is charged when it finishes successfully: `credits.charged` is 0 and `credits.pending` says what it will cost.
|
|
@@ -6517,7 +6537,7 @@ const listStudioModels = (options) => (options?.client ?? client).get({
|
|
|
6517
6537
|
/**
|
|
6518
6538
|
* Create a prediction model and start training it
|
|
6519
6539
|
*
|
|
6520
|
-
* Define a model — what to predict, for whom, in which state, and the data points to use — and start training it. It answers at once with `status: training` and `expectedMinutes`, a range that depends on the size of the state: a couple of minutes for a small state, 15 to 25 for the largest (an estimate; say the range, and say it is an estimate). Read the model with getStudioModel until it is `ready` or `refused`: `progress` gives the numbered step it is on and how long is left. `features` is the heart of it: the data points the person believes matter. Their own knowledge can be data points too — columns of their uploaded outcomes table such as a lead source or a rating their team gives. To learn from their own results instead of a market outcome, pass `outcomeSource` (an uploaded table with a home, a date and what happened on every row); that usually helps most. Everything a model learns from is taken strictly before each case's date, and a data point that could show it the answer is refused with the reason. To try a different list of data points, send the same `name` with `replace: true`, or a new name with `basedOn`: the new report card says what changed. An uploaded file's table is named `upload_<name>` (the upload `my_deals` is the table `upload_my_deals`); a wrong name is refused with the names that exist. A request that cannot work is refused now with a clear reason (`error`, `code`, and the numbers in `details`).
|
|
6540
|
+
* Define a model — what to predict, for whom, in which state, and the data points to use — and start training it. It answers at once with `status: training` and `expectedMinutes`, a range that depends on the size of the state: a couple of minutes for a small state, 15 to 25 for the largest (an estimate; say the range, and say it is an estimate). Read the model with getStudioModel until it is `ready` or `refused`: `progress` gives the numbered step it is on and how long is left. `features` is the heart of it: the data points the person believes matter. Their own knowledge can be data points too — columns of their uploaded outcomes table such as a lead source or a rating their team gives. To learn from their own results instead of a market outcome, pass `outcomeSource` (an uploaded table with a home, a date and what happened on every row); that usually helps most. Everything a model learns from is taken strictly before each case's date, and a data point that could show it the answer is refused with the reason. To try a different list of data points, send the same `name` with `replace: true`, or a new name with `basedOn`: the new report card says what changed. An uploaded file's table is named `upload_<name>` (the upload `my_deals` is the table `upload_my_deals`); a wrong name is refused with the names that exist. Data points marked `needsFairLendingReview` describe the neighborhood and need neighborhood data enabled for the organization (`neighborhoodDataAllowed` on getStudioModelOptions): without it a model that uses them — including one that leaves `features` out, which means every data point — is refused with `403 entitlement_missing`, naming them in `details.dataPoints`; tell the person to ask their ModelMatch admin, or pick other data points. A request that cannot work is refused now with a clear reason (`error`, `code`, and the numbers in `details`). An organization can have a few models running at once (3 by default; past that, `409 model_training_in_progress` says how many are running and the limit), and a model runs once at a time; up to 10 models. 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
6521
6541
|
*/
|
|
6522
6542
|
const createStudioModel = (options) => (options.client ?? client).post({
|
|
6523
6543
|
security: [{
|
|
@@ -6551,6 +6571,22 @@ const getStudioModelOptions = (options) => (options?.client ?? client).get({
|
|
|
6551
6571
|
...options
|
|
6552
6572
|
});
|
|
6553
6573
|
/**
|
|
6574
|
+
* A model ModelMatch publishes: its report card
|
|
6575
|
+
*
|
|
6576
|
+
* The report card of a prediction model ModelMatch trains and publishes for every organization; its scores are the published table `table`. If `hasCaution` is true, say `caution` FIRST: the model fell behind the best simple rule in part of the test period while staying better than random. Then: what it predicts (`predicts`), the `headline` as written, what it learned from and was tested on (`learnedFrom.sentence`), the lift sentences (`metrics.top10`, `metrics.top1`), the three `metrics.checks`, the data points that mattered (`dataPoints.used`, strongest first, with how much the model leaned on each — not how much it causes the outcome) and the ones it barely used (`dataPoints.rejected`), and the `caveats`. Never promise accuracy, and never call a score a probability unless `metrics.calibrated` is true. Free.
|
|
6577
|
+
*/
|
|
6578
|
+
const getStudioPublishedModel = (options) => (options.client ?? client).get({
|
|
6579
|
+
security: [{
|
|
6580
|
+
name: "x-api-key",
|
|
6581
|
+
type: "apiKey"
|
|
6582
|
+
}, {
|
|
6583
|
+
scheme: "bearer",
|
|
6584
|
+
type: "http"
|
|
6585
|
+
}],
|
|
6586
|
+
url: "/v1/studio/models/published/{table}",
|
|
6587
|
+
...options
|
|
6588
|
+
});
|
|
6589
|
+
/**
|
|
6554
6590
|
* Delete a model, its report card and its scores, permanently
|
|
6555
6591
|
*
|
|
6556
6592
|
* Delete a model: the trained model, its report card and its scores table. The table leaves the catalog at once, and questions and jobs that read it stop working. A run in progress is stopped. This cannot be undone. Free.
|
|
@@ -6585,7 +6621,7 @@ const getStudioModel = (options) => (options.client ?? client).get({
|
|
|
6585
6621
|
/**
|
|
6586
6622
|
* Refresh a model's scores with the latest data
|
|
6587
6623
|
*
|
|
6588
|
-
* Score the model's population again as of today, with the trained model as it is. The current scores stay queryable until the new ones are ready; read the model with getStudioModel to see when (`refresh` goes back to null and `scores.asOf` moves); `expectedMinutes` says how long it is expected to take. Pass `retrain: true` to also train it again on the latest data (the same data points, a fresh report card; if it no longer passes its checks it becomes `refused` and its scores are taken down). A model with a `weekly` or `monthly` schedule is refreshed on its own. 10 credits for refreshed scores, charged once, the same way (a scheduled refresh too). 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
6624
|
+
* Score the model's population again as of today, with the trained model as it is. The current scores stay queryable until the new ones are ready; read the model with getStudioModel to see when (`refresh` goes back to null and `scores.asOf` moves); `expectedMinutes` says how long it is expected to take, and `progress` which step it is on. Pass `retrain: true` to also train it again on the latest data (the same data points, a fresh report card; if it no longer passes its checks it becomes `refused` and its scores are taken down). A retrain of a model that uses neighborhood data points needs neighborhood data enabled for the organization, like creating one (`403 entitlement_missing` otherwise); a plain refresh of the scores does not. While it retrains the model stays `ready` with its current `card` and scores, and `progress` shows the training exactly as for a new model — the numbered step, the time left and the live `progress.trace`; the new card (with its final `trace`) replaces the current one when the run is published. A model with a `weekly` or `monthly` schedule is refreshed on its own. 10 credits for refreshed scores, charged once, the same way (a scheduled refresh too). 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
6589
6625
|
*/
|
|
6590
6626
|
const refreshStudioModel = (options) => (options.client ?? client).post({
|
|
6591
6627
|
security: [{
|
|
@@ -6707,4 +6743,4 @@ const completeStudioUpload = (options) => (options.client ?? client).post({
|
|
|
6707
6743
|
...options
|
|
6708
6744
|
});
|
|
6709
6745
|
//#endregion
|
|
6710
|
-
export { client as _heyApiClient, actionCrmCallerId, addCrmContactMethod, addCrmListMember, addCrmListMembersBulk, addCrmNote, addCrmRecord, addCrmRecordsBulk, addWatchedAgent, addWatchedArea, addWatchedDocument, agentAnalyticsChart, agentAnalyticsSummary, agentAnalyticsTimeSeries, agentBuilders, agentCities, agentCompanies, agentCounties, agentLenders, agentLoanMix, agentMarkets, agentMortgagedTimeSeries, agentOffices, agentOriginators, agentProperties, agentRelated, agentSales, agentStates, agentTitleCompanies, agentTitleCompaniesTimeSeries, agentZipCodes, analyzeCrmCall, applyCrmEnrichment, applyCrmListMiUpdates, applyCrmListTemplate, applyCrmMiUpdates, branchAnalyticsChart, branchAnalyticsSummary, branchAnalyticsTimeSeries, branchCities, branchCommunityLendingMap, branchCounties, branchLenders, branchLoans, branchOriginators, branchRoster, branchStates, branchStats, branchTitleCompanies, cancelAgentsBulkDeliveryJob, cancelBranchesBulkDeliveryJob, cancelCompaniesBulkDeliveryJob, cancelEnrichBulkJob, cancelLoansBulkDeliveryJob, cancelOriginatorsBulkDeliveryJob, cancelPropertiesBulkDeliveryJob, checkCrmImport, companyAgents, companyAnalyticsChart, companyAnalyticsSummary, companyAnalyticsTimeSeries, companyBranches, companyBrokers, companyCities, companyCommunityLendingBenchmark, companyCommunityLendingMap, companyCounties, companyDepartureStatus, companyEarlyExits, companyEmployeeStats, companyEmployment, companyHeadcount, companyLenders, companyMarkets, companyMoverProduction, companyOffices, companyOriginators, companyRelated, companyRetention, companyRetentionActiveListings, companyRetentionCaptured, companyRetentionLikelyToSell, companySponsoredIndividuals, companySponsorshipMovement, companyStates, companyTalentFlow, companyTitleCompanies, companyZipCodes, completeStudioUpload, countAgents, countBranches, countCompanies, countLenders, countLoans, countOffices, countOriginators, countProperties, countSales, createAgentContactSubmission, createAlertSubscription, createClient, createCrmList, createCrmListField, createCrmManualRecord, createCrmMeeting, createCrmObjectField, createCrmRecord, createCrmTask, createCrmTemplate, createMyAlertRecipe, createOriginatorContactSubmission, createPropertyTransactionFlag, createSavedFilter, createStudioJob, createStudioModel, createStudioUpload, crmLenderChannels, crmLoLoanMix, crmLoMomentum, crmLoSponsorLocation, crmSimilarOriginators, declineCrmMiUpdate, deleteAlertSubscription, deleteCrmCallerId, deleteCrmList, deleteCrmListField, deleteCrmMeeting, deleteCrmNote, deleteCrmObjectField, deleteCrmRecord, deleteCrmRecords, deleteCrmTask, deleteCrmTemplate, deleteMyAlertRecipe, deleteSavedFilter, deleteStudioJob, deleteStudioModel, deleteStudioUpload, describeCrmRecordsOnAdd, dismissCrmListMiUpdates, dismissCrmMiUpdates, editCrmLoggedActivity, editCrmNote, enrichPropertiesBatch, enrichPropertiesBulk, enrichProperty, filterCrmListMembers, findCrmRecordByNmls, generateCrmRecordDescription, getAgent, getAgentsBulkDeliveryJob, getAlertConditions, getAlertEmailTokens, getAlertUnreadCount, getBranch, getBranchesBulkDeliveryJob, getCompaniesBulkDeliveryJob, getCompany, getCrmActiveCall, getCrmActivityReport, getCrmCall, getCrmCallTranscript, getCrmCustomValues, getCrmImport, getCrmImportJob, getCrmList, getCrmListMemberIds, getCrmListMiUpdates, getCrmListShares, getCrmMiUpdates, getCrmOutcomesReport, getCrmOverrides, getCrmProductionEnrichJob, getCrmRecordAccess, getCrmRecordAccessRequest, getCrmRecordConnections, getCrmRecordMemberIds, getCrmRecordProfile, getCrmTemplate, getCrmTemplateShares, getEnrichBulkJob, getHubspotPushStatus, getLender, getLoan, getLoansBulkDeliveryJob, getMe, getMeCredits, getMePlan, getOffice, getOriginator, getOriginatorAgentPulseSignals, getOriginatorClientRetentionSignals, getOriginatorLoMoveSignal, getOriginatorsBulkDeliveryJob, getPropertiesBulkDeliveryJob, getProperty, getRealtimeConfig, getSale, getSavedFilter, getSavedFilterShares, getSearchToken, getStudioCatalog, getStudioJob, getStudioModel, getStudioModelOptions, getStudioQueryResult, grantCrmListAccess, grantCrmRecordAccess, grantCrmRecordAccessRequest, grantSavedFilterAccess, hangupCrmCall, importCrmRecords, instantSearch, lenderCities, lenderCompanies, lenderCounties, lenderOriginators, lenderStates, linkCrmRecord, listAgentOfficeGroups, listAgents, listAlertDigests, listAlertLog, listAlertRecipes, listAlertSubscriptions, listBranches, listCompanies, listCrmActivity, listCrmCallerIds, listCrmContactMethods, listCrmCustomFields, listCrmImportRows, listCrmImports, listCrmListAssignees, listCrmListFields, listCrmListMemberships, listCrmListShareableMembers, listCrmLists, listCrmMeetings, listCrmMembers, listCrmOrgMembers, listCrmRecordShareableMembers, listCrmRecordShares, listCrmReferencedActivity, listCrmTasks, listCrmTemplates, listCrmWorkspaceMeetings, listCrmWorkspaceTasks, listEnrichments, listLenders, listLoMoveSignals, listLoans, listMyAlertRecipes, listOffices, listOriginators, listProperties, listSales, listSavedFilterShareableMembers, listSavedFilters, listStudioJobs, listStudioModels, listStudioUploads, listWatchedAgents, listWatchedAreas, listWatchedDocuments, loanRelated, loansAnalyticsChart, loansAnalyticsSummary, loansAnalyticsTimeSeries, logCrmActivity, lookupCompanies, mapSales, markAlertDigestRead, markAlertRead, markAllAlertsRead, marketAnalyticsChart, marketAnalyticsSummary, marketAnalyticsTimeSeries, marketCommunityLending, marketMovementActivity, marketMovementByState, marketMovementCohortPayoff, marketMovementMostGained, marketMovementMostLost, marketMovementMovers, marketMovementRankings, marketMovementStats, marketMovementTransitions, marketSignals, officeAgents, officeBuilders, officeLenders, officeLoanTypes, officeOriginators, originatorAgents, originatorAnalyticsChart, originatorAnalyticsSummary, originatorAnalyticsTimeSeries, originatorBranches, originatorBrokers, originatorBuilders, originatorCitiesBreakdown, originatorCommunityLendingBenchmark, originatorCommunityLendingMap, originatorCompanies, originatorCountiesBreakdown, originatorLenders, originatorLoans, originatorMarkets, originatorOffices, originatorProperties, originatorRelated, originatorRetention, originatorRetentionCaptured, originatorStatesBreakdown, originatorTitleCompanies, originatorZipCodes, placeCrmCall, previewAlertEmailTemplate, previewAlertRecipe, previewAlerts, previewMyAlertRecipe, propertiesAnalyticsChart, propertiesAnalyticsSummary, propertyRelated, pushToHubspot, reconcileCrmMeetings, refreshCrmRecordMirror, refreshStudioModel, removeCrmContactMethod, removeCrmListMember, removeWatchedAgent, removeWatchedArea, removeWatchedDocument, requestCrmAccess, requestCrmRecordAccess, resolveProperties, retrieveLocation, revokeCrmListAccess, revokeCrmRecordAccess, revokeSavedFilterAccess, runStudioJob, runStudioQuery, saleRelated, salesAnalyticsChart, salesAnalyticsSummary, salesAnalyticsTimeSeries, salesMarketStats, searchCrmEmailRecipients, searchCrmMatchCandidates, searchCrmMentionRecords, searchCrmRecords, searchProperties, sendCrmEmail, setCrmCallAnalysis, setCrmCustomValue, setCrmOverride, setCrmRecordOwner, setDefaultCrmCallerId, shareCrmTemplate, submitAgentsBulkDelivery, submitBranchesBulkDelivery, submitCompaniesBulkDelivery, submitLoansBulkDelivery, submitOriginatorsBulkDelivery, submitPropertiesBulkDelivery, subscribeAlertRecipe, suggestLocations, suggestOfficeNames, transcribeCrmCall, transferCrmListOwnership, undoCrmImport, unshareCrmTemplate, unsubscribeAlertRecipe, updateAlertConditions, updateCrmContactMethod, updateCrmList, updateCrmListField, updateCrmMeeting, updateCrmObjectField, updateCrmTask, updateCrmTemplate, updateMe, updateMyAlertRecipe, updateSavedFilter };
|
|
6746
|
+
export { client as _heyApiClient, actionCrmCallerId, addCrmContactMethod, addCrmListMember, addCrmListMembersBulk, addCrmNote, addCrmRecord, addCrmRecordsBulk, addWatchedAgent, addWatchedArea, addWatchedDocument, agentAnalyticsChart, agentAnalyticsSummary, agentAnalyticsTimeSeries, agentBuilders, agentCities, agentCompanies, agentCounties, agentLenders, agentLoanMix, agentMarkets, agentMortgagedTimeSeries, agentOffices, agentOriginators, agentProperties, agentRelated, agentSales, agentStates, agentTitleCompanies, agentTitleCompaniesTimeSeries, agentZipCodes, analyzeCrmCall, applyCrmEnrichment, applyCrmListMiUpdates, applyCrmListTemplate, applyCrmMiUpdates, branchAnalyticsChart, branchAnalyticsSummary, branchAnalyticsTimeSeries, branchCities, branchCommunityLendingMap, branchCounties, branchLenders, branchLoans, branchOriginators, branchRoster, branchStates, branchStats, branchTitleCompanies, cancelAgentsBulkDeliveryJob, cancelBranchesBulkDeliveryJob, cancelCompaniesBulkDeliveryJob, cancelEnrichBulkJob, cancelLoansBulkDeliveryJob, cancelOriginatorsBulkDeliveryJob, cancelPropertiesBulkDeliveryJob, checkCrmImport, companyAgents, companyAnalyticsChart, companyAnalyticsSummary, companyAnalyticsTimeSeries, companyBranches, companyBrokers, companyCities, companyCommunityLendingBenchmark, companyCommunityLendingMap, companyCounties, companyDepartureStatus, companyEarlyExits, companyEmployeeStats, companyEmployment, companyHeadcount, companyLenders, companyMarkets, companyMoverProduction, companyOffices, companyOriginators, companyRelated, companyRetention, companyRetentionActiveListings, companyRetentionCaptured, companyRetentionLikelyToSell, companySponsoredIndividuals, companySponsorshipMovement, companyStates, companyTalentFlow, companyTitleCompanies, companyZipCodes, completeStudioUpload, countAgents, countBranches, countCompanies, countLenders, countLoans, countOffices, countOriginators, countProperties, countSales, createAgentContactSubmission, createAlertSubscription, createClient, createCrmList, createCrmListField, createCrmManualRecord, createCrmMeeting, createCrmObjectField, createCrmRecord, createCrmTask, createCrmTemplate, createMyAlertRecipe, createOriginatorContactSubmission, createPropertyTransactionFlag, createSavedFilter, createStudioJob, createStudioModel, createStudioUpload, crmLenderChannels, crmLoLoanMix, crmLoMomentum, crmLoSponsorLocation, crmSimilarOriginators, declineCrmMiUpdate, deleteAlertSubscription, deleteCrmCallerId, deleteCrmList, deleteCrmListField, deleteCrmMeeting, deleteCrmNote, deleteCrmObjectField, deleteCrmRecord, deleteCrmRecords, deleteCrmTask, deleteCrmTemplate, deleteMyAlertRecipe, deleteSavedFilter, deleteStudioJob, deleteStudioModel, deleteStudioUpload, describeCrmRecordsOnAdd, dismissCrmListMiUpdates, dismissCrmMiUpdates, editCrmLoggedActivity, editCrmNote, enrichPropertiesBatch, enrichPropertiesBulk, enrichProperty, filterCrmListMembers, findCrmRecordByNmls, generateCrmRecordDescription, getAgent, getAgentsBulkDeliveryJob, getAlertConditions, getAlertEmailTokens, getAlertUnreadCount, getBranch, getBranchesBulkDeliveryJob, getCompaniesBulkDeliveryJob, getCompany, getCrmActiveCall, getCrmActivityReport, getCrmCall, getCrmCallTranscript, getCrmCustomValues, getCrmImport, getCrmImportJob, getCrmList, getCrmListMemberIds, getCrmListMiUpdates, getCrmListShares, getCrmMiUpdates, getCrmOutcomesReport, getCrmOverrides, getCrmProductionEnrichJob, getCrmRecordAccess, getCrmRecordAccessRequest, getCrmRecordConnections, getCrmRecordMemberIds, getCrmRecordProfile, getCrmTemplate, getCrmTemplateShares, getEnrichBulkJob, getHubspotPushStatus, getLender, getLoan, getLoansBulkDeliveryJob, getMe, getMeCredits, getMePlan, getOffice, getOriginator, getOriginatorAgentPulseSignals, getOriginatorClientRetentionSignals, getOriginatorLoMoveSignal, getOriginatorsBulkDeliveryJob, getPropertiesBulkDeliveryJob, getProperty, getRealtimeConfig, getSale, getSavedFilter, getSavedFilterShares, getSearchToken, getStudioCatalog, getStudioJob, getStudioModel, getStudioModelOptions, getStudioPublishedModel, getStudioQueryResult, grantCrmListAccess, grantCrmRecordAccess, grantCrmRecordAccessRequest, grantSavedFilterAccess, hangupCrmCall, importCrmRecords, instantSearch, lenderCities, lenderCompanies, lenderCounties, lenderOriginators, lenderStates, linkCrmRecord, listAgentOfficeGroups, listAgents, listAlertDigests, listAlertLog, listAlertRecipes, listAlertSubscriptions, listBranches, listCompanies, listCrmActivity, listCrmCallerIds, listCrmContactMethods, listCrmCustomFields, listCrmImportRows, listCrmImports, listCrmListAssignees, listCrmListFields, listCrmListMemberships, listCrmListShareableMembers, listCrmLists, listCrmMeetings, listCrmMembers, listCrmOrgMembers, listCrmRecordShareableMembers, listCrmRecordShares, listCrmReferencedActivity, listCrmTasks, listCrmTemplates, listCrmWorkspaceMeetings, listCrmWorkspaceTasks, listEnrichments, listLenders, listLoMoveSignals, listLoans, listMyAlertRecipes, listOffices, listOriginators, listProperties, listSales, listSavedFilterShareableMembers, listSavedFilters, listStudioJobs, listStudioModels, listStudioUploads, listWatchedAgents, listWatchedAreas, listWatchedDocuments, loanRelated, loansAnalyticsChart, loansAnalyticsSummary, loansAnalyticsTimeSeries, logCrmActivity, lookupCompanies, mapSales, markAlertDigestRead, markAlertRead, markAllAlertsRead, marketAnalyticsChart, marketAnalyticsSummary, marketAnalyticsTimeSeries, marketCommunityLending, marketMovementActivity, marketMovementByState, marketMovementCohortPayoff, marketMovementMostGained, marketMovementMostLost, marketMovementMovers, marketMovementRankings, marketMovementStats, marketMovementTransitions, marketSignals, officeAgents, officeBuilders, officeLenders, officeLoanTypes, officeOriginators, originatorAgents, originatorAnalyticsChart, originatorAnalyticsSummary, originatorAnalyticsTimeSeries, originatorBranches, originatorBrokers, originatorBuilders, originatorCitiesBreakdown, originatorCommunityLendingBenchmark, originatorCommunityLendingMap, originatorCompanies, originatorCountiesBreakdown, originatorLenders, originatorLoans, originatorMarkets, originatorOffices, originatorProperties, originatorRelated, originatorRetention, originatorRetentionCaptured, originatorStatesBreakdown, originatorTitleCompanies, originatorZipCodes, placeCrmCall, previewAlertEmailTemplate, previewAlertRecipe, previewAlerts, previewMyAlertRecipe, propertiesAnalyticsChart, propertiesAnalyticsSummary, propertyRelated, pushToHubspot, reconcileCrmMeetings, refreshCrmRecordMirror, refreshStudioModel, removeCrmContactMethod, removeCrmListMember, removeWatchedAgent, removeWatchedArea, removeWatchedDocument, requestCrmAccess, requestCrmRecordAccess, resolveProperties, retrieveLocation, revokeCrmListAccess, revokeCrmRecordAccess, revokeSavedFilterAccess, runStudioJob, runStudioQuery, saleRelated, salesAnalyticsChart, salesAnalyticsSummary, salesAnalyticsTimeSeries, salesMarketStats, searchCrmEmailRecipients, searchCrmMatchCandidates, searchCrmMentionRecords, searchCrmRecords, searchProperties, sendCrmEmail, setCrmCallAnalysis, setCrmCustomValue, setCrmOverride, setCrmRecordOwner, setDefaultCrmCallerId, shareCrmTemplate, submitAgentsBulkDelivery, submitBranchesBulkDelivery, submitCompaniesBulkDelivery, submitLoansBulkDelivery, submitOriginatorsBulkDelivery, submitPropertiesBulkDelivery, subscribeAlertRecipe, suggestLocations, suggestOfficeNames, transcribeCrmCall, transferCrmListOwnership, undoCrmImport, unshareCrmTemplate, unsubscribeAlertRecipe, updateAlertConditions, updateCrmContactMethod, updateCrmList, updateCrmListField, updateCrmMeeting, updateCrmObjectField, updateCrmTask, updateCrmTemplate, updateMe, updateMyAlertRecipe, updateSavedFilter, updateStudioJob };
|
|
@@ -7826,7 +7826,7 @@ var Studio = class {
|
|
|
7826
7826
|
/**
|
|
7827
7827
|
* Save a question as a job
|
|
7828
7828
|
*
|
|
7829
|
-
* Save a SQL question to run again: on a schedule (`daily`, `weekly`) or only when asked (`manual`). Each run stores its result as a table named after the job, which later questions — and later jobs — can query like any other table. Name the `keys` (the columns that identify one row) to get 'what changed since the last run', and add `alerts` to flag new rows, removed rows or a number crossing a threshold. The SQL is checked when the job is saved: an unknown table or column, or a key that is not in the result, is refused here rather than at the first run. Saving does not run the job. Saving is free; each run that succeeds costs 10 credits, including the runs a `daily` or `weekly` schedule starts.
|
|
7829
|
+
* Save a SQL question to run again: on a schedule (`daily`, `weekly`) or only when asked (`manual`). Each run stores its result as a table named after the job, which later questions — and later jobs — can query like any other table. Name the `keys` (the columns that identify one row) to get 'what changed since the last run', and add `alerts` to flag new rows, removed rows or a number crossing a threshold. When an alert matches on a scheduled run, the job's creator is emailed (once per hourly tick, every job of theirs in one email, also in their notifications); `notify: { email: false }` saves the job without those emails, and `updateStudioJob` changes it later. Webhooks are not available yet. The SQL is checked when the job is saved: an unknown table or column, or a key that is not in the result, is refused here rather than at the first run. Saving does not run the job. Saving is free; each run that succeeds costs 10 credits, including the runs a `daily` or `weekly` schedule starts.
|
|
7830
7830
|
*/
|
|
7831
7831
|
static createStudioJob(options) {
|
|
7832
7832
|
return (options.client ?? client).post({
|
|
@@ -7882,6 +7882,28 @@ var Studio = class {
|
|
|
7882
7882
|
});
|
|
7883
7883
|
}
|
|
7884
7884
|
/**
|
|
7885
|
+
* Change a job's settings
|
|
7886
|
+
*
|
|
7887
|
+
* Change how a saved job tells you about its alerts: `notify.email` false stops the email to the job's creator when an alert matches on a scheduled run; true turns it back on. Matched alerts are still recorded on each run. Free.
|
|
7888
|
+
*/
|
|
7889
|
+
static updateStudioJob(options) {
|
|
7890
|
+
return (options.client ?? client).patch({
|
|
7891
|
+
security: [{
|
|
7892
|
+
name: "x-api-key",
|
|
7893
|
+
type: "apiKey"
|
|
7894
|
+
}, {
|
|
7895
|
+
scheme: "bearer",
|
|
7896
|
+
type: "http"
|
|
7897
|
+
}],
|
|
7898
|
+
url: "/v1/studio/jobs/{name}",
|
|
7899
|
+
...options,
|
|
7900
|
+
headers: {
|
|
7901
|
+
"Content-Type": "application/json",
|
|
7902
|
+
...options.headers
|
|
7903
|
+
}
|
|
7904
|
+
});
|
|
7905
|
+
}
|
|
7906
|
+
/**
|
|
7885
7907
|
* Run a job now
|
|
7886
7908
|
*
|
|
7887
7909
|
* Run a saved job now. Answers `200` with the finished run (its row count, what changed and any alerts) when it ends within a few seconds; otherwise `202` with `status: running`, and the run carries on — read the job to see how it ended. A run that fails answers `422` with `code: job_failed` and the reason. One job runs at a time per organization. 10 credits for a run that succeeds; a failed run is free. A run that has succeeded by the time this returns is charged now (`credits.charged`, with `credits.remaining`). One still running is charged when it finishes successfully: `credits.charged` is 0 and `credits.pending` says what it will cost.
|
|
@@ -7920,7 +7942,7 @@ var Studio = class {
|
|
|
7920
7942
|
/**
|
|
7921
7943
|
* Create a prediction model and start training it
|
|
7922
7944
|
*
|
|
7923
|
-
* Define a model — what to predict, for whom, in which state, and the data points to use — and start training it. It answers at once with `status: training` and `expectedMinutes`, a range that depends on the size of the state: a couple of minutes for a small state, 15 to 25 for the largest (an estimate; say the range, and say it is an estimate). Read the model with getStudioModel until it is `ready` or `refused`: `progress` gives the numbered step it is on and how long is left. `features` is the heart of it: the data points the person believes matter. Their own knowledge can be data points too — columns of their uploaded outcomes table such as a lead source or a rating their team gives. To learn from their own results instead of a market outcome, pass `outcomeSource` (an uploaded table with a home, a date and what happened on every row); that usually helps most. Everything a model learns from is taken strictly before each case's date, and a data point that could show it the answer is refused with the reason. To try a different list of data points, send the same `name` with `replace: true`, or a new name with `basedOn`: the new report card says what changed. An uploaded file's table is named `upload_<name>` (the upload `my_deals` is the table `upload_my_deals`); a wrong name is refused with the names that exist. A request that cannot work is refused now with a clear reason (`error`, `code`, and the numbers in `details`).
|
|
7945
|
+
* Define a model — what to predict, for whom, in which state, and the data points to use — and start training it. It answers at once with `status: training` and `expectedMinutes`, a range that depends on the size of the state: a couple of minutes for a small state, 15 to 25 for the largest (an estimate; say the range, and say it is an estimate). Read the model with getStudioModel until it is `ready` or `refused`: `progress` gives the numbered step it is on and how long is left. `features` is the heart of it: the data points the person believes matter. Their own knowledge can be data points too — columns of their uploaded outcomes table such as a lead source or a rating their team gives. To learn from their own results instead of a market outcome, pass `outcomeSource` (an uploaded table with a home, a date and what happened on every row); that usually helps most. Everything a model learns from is taken strictly before each case's date, and a data point that could show it the answer is refused with the reason. To try a different list of data points, send the same `name` with `replace: true`, or a new name with `basedOn`: the new report card says what changed. An uploaded file's table is named `upload_<name>` (the upload `my_deals` is the table `upload_my_deals`); a wrong name is refused with the names that exist. Data points marked `needsFairLendingReview` describe the neighborhood and need neighborhood data enabled for the organization (`neighborhoodDataAllowed` on getStudioModelOptions): without it a model that uses them — including one that leaves `features` out, which means every data point — is refused with `403 entitlement_missing`, naming them in `details.dataPoints`; tell the person to ask their ModelMatch admin, or pick other data points. A request that cannot work is refused now with a clear reason (`error`, `code`, and the numbers in `details`). An organization can have a few models running at once (3 by default; past that, `409 model_training_in_progress` says how many are running and the limit), and a model runs once at a time; up to 10 models. 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
7924
7946
|
*/
|
|
7925
7947
|
static createStudioModel(options) {
|
|
7926
7948
|
return (options.client ?? client).post({
|
|
@@ -7958,6 +7980,24 @@ var Studio = class {
|
|
|
7958
7980
|
});
|
|
7959
7981
|
}
|
|
7960
7982
|
/**
|
|
7983
|
+
* A model ModelMatch publishes: its report card
|
|
7984
|
+
*
|
|
7985
|
+
* The report card of a prediction model ModelMatch trains and publishes for every organization; its scores are the published table `table`. If `hasCaution` is true, say `caution` FIRST: the model fell behind the best simple rule in part of the test period while staying better than random. Then: what it predicts (`predicts`), the `headline` as written, what it learned from and was tested on (`learnedFrom.sentence`), the lift sentences (`metrics.top10`, `metrics.top1`), the three `metrics.checks`, the data points that mattered (`dataPoints.used`, strongest first, with how much the model leaned on each — not how much it causes the outcome) and the ones it barely used (`dataPoints.rejected`), and the `caveats`. Never promise accuracy, and never call a score a probability unless `metrics.calibrated` is true. Free.
|
|
7986
|
+
*/
|
|
7987
|
+
static getStudioPublishedModel(options) {
|
|
7988
|
+
return (options.client ?? client).get({
|
|
7989
|
+
security: [{
|
|
7990
|
+
name: "x-api-key",
|
|
7991
|
+
type: "apiKey"
|
|
7992
|
+
}, {
|
|
7993
|
+
scheme: "bearer",
|
|
7994
|
+
type: "http"
|
|
7995
|
+
}],
|
|
7996
|
+
url: "/v1/studio/models/published/{table}",
|
|
7997
|
+
...options
|
|
7998
|
+
});
|
|
7999
|
+
}
|
|
8000
|
+
/**
|
|
7961
8001
|
* Delete a model, its report card and its scores, permanently
|
|
7962
8002
|
*
|
|
7963
8003
|
* Delete a model: the trained model, its report card and its scores table. The table leaves the catalog at once, and questions and jobs that read it stop working. A run in progress is stopped. This cannot be undone. Free.
|
|
@@ -7996,7 +8036,7 @@ var Studio = class {
|
|
|
7996
8036
|
/**
|
|
7997
8037
|
* Refresh a model's scores with the latest data
|
|
7998
8038
|
*
|
|
7999
|
-
* Score the model's population again as of today, with the trained model as it is. The current scores stay queryable until the new ones are ready; read the model with getStudioModel to see when (`refresh` goes back to null and `scores.asOf` moves); `expectedMinutes` says how long it is expected to take. Pass `retrain: true` to also train it again on the latest data (the same data points, a fresh report card; if it no longer passes its checks it becomes `refused` and its scores are taken down). A model with a `weekly` or `monthly` schedule is refreshed on its own. 10 credits for refreshed scores, charged once, the same way (a scheduled refresh too). 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
8039
|
+
* Score the model's population again as of today, with the trained model as it is. The current scores stay queryable until the new ones are ready; read the model with getStudioModel to see when (`refresh` goes back to null and `scores.asOf` moves); `expectedMinutes` says how long it is expected to take, and `progress` which step it is on. Pass `retrain: true` to also train it again on the latest data (the same data points, a fresh report card; if it no longer passes its checks it becomes `refused` and its scores are taken down). A retrain of a model that uses neighborhood data points needs neighborhood data enabled for the organization, like creating one (`403 entitlement_missing` otherwise); a plain refresh of the scores does not. While it retrains the model stays `ready` with its current `card` and scores, and `progress` shows the training exactly as for a new model — the numbered step, the time left and the live `progress.trace`; the new card (with its final `trace`) replaces the current one when the run is published. A model with a `weekly` or `monthly` schedule is refreshed on its own. 10 credits for refreshed scores, charged once, the same way (a scheduled refresh too). 50 credits for a model that passes its checks, charged once when it has finished: by the first call that reads it or, if nobody does, on its own within about two hours. A model that is refused or fails is free.
|
|
8000
8040
|
*/
|
|
8001
8041
|
static refreshStudioModel(options) {
|
|
8002
8042
|
return (options.client ?? client).post({
|