diff --git a/files/.DS_Store b/files/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..fb6a3f0bfd96195a73edf51014f9ba84d7a05c76 Binary files /dev/null and b/files/.DS_Store differ diff --git a/files/arthur-docs-markdown/.DS_Store b/files/arthur-docs-markdown/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..c097322e8739115e0e9c82ae4e243c580f80f160 Binary files /dev/null and b/files/arthur-docs-markdown/.DS_Store differ diff --git a/files/arthur-docs-markdown/api/.DS_Store b/files/arthur-docs-markdown/api/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..5008ddfcf53c02e82d7eee2e57c38e5672ef89f6 Binary files /dev/null and b/files/arthur-docs-markdown/api/.DS_Store differ diff --git a/files/arthur-docs-markdown/api/openapi_v3.md.txt b/files/arthur-docs-markdown/api/openapi_v3.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e0238d5afabaade71627be1bda3deb187cb00b39 --- /dev/null +++ b/files/arthur-docs-markdown/api/openapi_v3.md.txt @@ -0,0 +1,123 @@ +openapi: 3.0.0 info: title: Arthur AI API version: "3.0.0" description: Arthur AI API Documentation for https://{dashboardUrl}/api/v3 tags: - name: auth description: Requests to our API should include the JWT returned from the login endpoint in either a header called "Authorization" or be added to the cookie header. - name: organizations description: Endpoints to create and manage organizations - name: models description: The endpoints allow us to create, fetch, update, and archive models. - name: tags description: Tags are created and assigned to models through the /models endpoints. Since tags are created at the organization level, these endpoints provide an interface for viewing the tags in an organization and editing or deleting existing tags. - name: inferences description: An inference can be thought of as a "prediction" - it consists of all the model input attributes and values and the predicted values. An inference can also include ground truth data and non-input data. These endpoints provide us with the functionality to to send, update, and fetch inferences. - name: explainability description: These endpoints provide a way to configure explainability for a model. - name: alert rules description: These endpoints allow us to create rules for when alerts should be triggered and configure the alert behavior. Alerts can be configured for the following (case insensitive) metrics ['average prediction', 'psi data drift', 'psi data drift reference set', 'rmse', 'total inference count', 'total inference count by class', 'psi batch data drift reference set'] or can alternatively use a custom metric. - name: alerts description: Endpoints to fetch and update triggered alerts. - name: metrics description: Endpoints to create and update a model's metrics - name: query description: Our query endpoints take in a sql like request body and return either inferences or inference metrics for a model. See the [Query Guide](/api-query-guide/index.html) for more information. - name: enrichments description: These endpoints allow for configuration and status retrieval of enrichments. - name: users description: Endpoints to create and manage users within an organization. These are disabled for 3rd party authenticated access. - name: authorization description: Endpoints to manage role-based access control for actions within the Arthur platform. See the [Custom RBAC Guide](/access-control/authorization.html) for more information. - name: insights description: Insights are auto-generated observations on model performance. See the [Alerting Guide](/alert-rules-guide/alert\_rules\_guide.html) for more information. - name: reference data description: Reference Data serves as the baseline against which new inferences are compared to quantify drift and stability of incoming data streams. See [Reference Data](/getting-started/setting\_reference\_set.html) for more information. - name: alert-summary description: Endpoints to create and manage alert summary reports. Reports can aggregate alert information across models in an org and be configured to notify users on a daily or weekly cadence. - name: usage description: Get usage information for Arthur in the available categories - inferences, explanations, organization, ground\_truth, and reference\_data. + + +servers: - url: https://app.arthur.ai/api/v3 paths: /login: post: summary: /login description: If the login attempt is successful, the user will be returned in the response body and an HttpOnly, set-cookie "Authorization" header will be returned that contains a JWT to be used in subsequent requests to the API in either the "Authorization" or cookie header. requestBody: description: The login credentials. content: application/json: schema: $ref: '#/components/schemas/LoginRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/User' headers: Set-Cookie: schema: type: string example: Authorization=abcde12345; HttpOnly; secure tags: - auth # \*\*\*\*\*\*\*\*\*\*\*\*\*\*\* Users endpoints \*\*\*\*\*\*\*\*\*\*\*\*\*\*\* /users: get: summary: /users description: Returns a paginated list of users. parameters: - name: page in: query required: false description: The page to fetch. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to order the users. By default, the users will be sorted by their email in asc order. Options are ['email', 'username', 'first\_name', 'last\_name']. To specify sort order, prepend the string with '+' for asc order and '-' for descending order, e.g. '-last\_name' will return the models sorted in desc order. schema: $ref: '#/components/schemas/Sort' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedUsers' security: - auth: [] tags: - users post: summary: /users description: Creates a new user. requestBody: description: The new user to create content: application/json: schema: $ref: '#/components/schemas/NewUserRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/User' security: - auth: [] tags: - users /users/me: get: summary: /users/me description: Returns the currently authenticated user. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/UserResponse' security: - auth: [ ] tags: - users patch: summary: /users/me description: Updates the currently authenticated user. requestBody: description: The user fields to update. content: application/json: schema: $ref: '#/components/schemas/UpdateCurrentUserRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/UserResponse' security: - auth: [] tags: - users /users/me/auth\_info: get: description: Returns authentication info for the calling, token-bearing user. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AuthenticationInfo' security: - api\_key: [ ] tags: - auth /users/{user\_id}: parameters: - in: path name: user\_id description: The unique uuid of the user schema: type: string required: true get: summary: /users/{user\_id} description: Returns a single user. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/User' security: - auth: [] tags: - users patch: summary: /users/{user\_id} description: Updates a user. Request to update the password must include the old password unless a super admin is making the request. requestBody: description: The user fields to update. content: application/json: schema: $ref: '#/components/schemas/UpdateUserRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/User' security: - auth: [] tags: - users delete: summary: /users/{user\_id} description: Deletes a user (by marking them as inactive) and invalidates any existing api keys. responses: '204': description: Successfully deleted the user. security: - auth: [] tags: - users /users/invite\_users: post: summary: /users/invite\_users description: Send email invitations to have users join the requesters organization. requestBody: description: A list of emails to invite. content: application/json: schema: properties: invite\_emails: type: array required: true items: type: string example: "arthur@arthur.ai" description: A list of emails to invite to the organization of the inviting user return\_direct\_links: type: boolean required: false default: false example: true description: If set to true, invite emails will not be sent; instead, the signup links will be returned directly in the api response. If set to false email invites will be sent and the response body will be null. custom\_dashboard\_url: type: string required: false example: "beta.kots.dev.arthur.ai" description: Set this if you want the invite links to be prefixed with a URL different from the default organization\_id: type: string required: false format: uuid example: "b4e2c14d-85f6-405a-b184-ca9fbca2604f" description: Set this if and only if calling as superadmin, otherwise it will return an error; this specifies the org to invite the users to responses: '200': description: Successfully sent email invites. content: application/json: schema: $ref: '#/components/schemas/InviteResponse' security: - auth: [] tags: - users /organizations: get: description: Returns a paginated list of organizations. Requires a global role. parameters: - name: name in: query required: false description: Filters for the organization with this exact name. This is case sensitive. schema: type: string - name: page in: query required: false description: The page to fetch. Defaults to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to order the organizations. Organizations will be sorted by name and will default to being sorted in ascending order. To set in descending order, set the value to "-name". schema: $ref: '#/components/schemas/Sort' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedOrganizations' security: - api\_key: [] tags: - organizations post: description: Creates a new organization. Requires a global role. requestBody: description: The new organization to create content: application/json: schema: $ref: '#/components/schemas/NewOrganizationRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/Organization' security: - api\_key: [] tags: - organizations /organizations/{organization\_id}: parameters: - in: path name: organization\_id description: The unique uuid of the organization schema: type: string format: uuid example: f562c43a-77ea-49d2-b268-ae082282bfb7 required: true get: description: Fetches a specific organization. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/Organization' security: - api\_key: [] tags: - organizations patch: description: Updates the organization's name and plan parameters: - in: path name: organization\_id description: The unique uuid of the organization to be updated schema: type: string format: uuid example: f75d9ecd-bdba-4662-b013-00391b7a18df required: true requestBody: description: The new name and/or plan of the organization to be updated content: application/json: schema: $ref: '#/components/schemas/UpdateOrganizationRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/Organization' security: - api\_key: [] tags: - organizations delete: parameters: - in: path name: organization\_id description: The unique uuid of the organization schema: type: string format: uuid example: 8ef91597-71b7-4559-8cba-4734caa558c0 required: true description: Deletes the organization. This is a HARD delete. This request will fail if there are any objects associated with this organization (e.g. users, models). responses: '204': description: Success security: - api\_key: [] tags: - organizations /organizations/{organization\_id}/limits: get: parameters: - in: path name: organization\_id description: The unique uuid of the organization schema: type: string format: uuid example: 144684e1-736b-4087-9174-53484082f889 required: true description: Retrieves the specified organization's limits based on its license plan responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/OrganizationLimits' security: - api\_key: [ ] tags: - organizations /organizations/current: get: description: Returns the calling user's current organization. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/Organization' security: - api\_key: [ ] tags: - organizations put: description: Sets your current organization. requestBody: description: ID of organization to set. content: application/json: schema: $ref: '#/components/schemas/SetCurrentOrganizationRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/SetCurrentOrganizationRequest' security: - api\_key: [ ] tags: - organizations /organizations/me: get: description: Returns all the organizations that the calling user is in responses: '200': description: Success content: application/json: schema: type: array items: $ref: '#/components/schemas/Organization' security: - api\_key: [ ] tags: - organizations /models: get: summary: /models description: Returns a paginated response of all the models within an organization. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedModelResponse' parameters: - name: include\_archived in: query required: false description: Indicates whether information about archived models should be returned. Defaults to false. schema: type: boolean default: false - name: latest\_version\_sequence\_nums in: query required: false description: If true, will only get the latest version model within each model group. If false, will return all versions of all model groups. schema: type: boolean default: false - name: display\_name in: query required: false description: If specified, will get models who have a display name that matches the search string. schema: type: string - name: input\_type in: query required: false description: If specified, will only get models with a matching input type. schema: type: string - name: output\_type in: query required: false description: If specified, will only get models with a matching output type. schema: type: string - name: status in: query required: false description: If specified, will only get models with a matching status. schema: type: string - name: tag in: query required: false description: If specified, will only get models who have the specified tag. schema: type: string - name: model\_group\_id in: query required: false description: If specified, will only get models who belong to the specified model group. schema: type: string - name: created\_since in: query required: false description: If specified, will only get models that were created on or after this time. Should be in ISO8601 string format. schema: type: string - name: expand in: query required: false description: If specified, will only expand the model response to include the corresponding information. Multiple `expand` query parameters can be specified; for example, to return expanded information on organization\_id and explainability, the request would include the query '?expand=explainability&expand=organization\_id'. Note that attributes is not currently a supported option. schema: type: string enum: - explainability - organization\_id - model\_group\_name - inference\_stats - critical\_alert\_count - health\_scores - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to sort the models. By default, the models will be sorted by their created date in asc order. Options are ['created\_at', 'partner\_model\_id', 'id', 'display\_name', 'model\_group\_name']. To specify sort order, pre-pend the string with '+' for asc order and '-' for descending order, e.g. '-partner\_model\_id' will return the models sorted in desc order. If sorting on model\_group\_name, you must also set a query parameter to expand the model\_group\_name. schema: $ref: '#/components/schemas/Sort' security: - auth: [] tags: - models post: summary: /models description: Creates a new model object. The model must have at least two attributes - one in stages (`NON\_INPUT\_DATA`, `PIPELINE\_INPUT`), and one in stage `PREDICTED\_VALUE`. requestBody: description: Model object to create content: application/json: schema: $ref: '#/components/schemas/ModelRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelObject' security: - auth: [] tags: - models /models/{model\_id}: parameters: - in: path name: model\_id schema: type: string required: true - in: query name: id\_type description: ID type the string in the model path refers to. This defaults to id. schema: enum: - id - partner\_model\_id default: id - in: query name: expand required: false description: Indicates whether additional information should be returned about an object. Multiple `expand` query parameters can be specified; for example, to return expanded information on attributes and explainability, the request would include the query '?expand=explainability&expand=attributes'. schema: type: string enum: - attributes - explainability - organization\_id get: summary: /models/{model\_id} responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelResponse' description: Retrieve a specific model object. security: - auth: [] tags: - models put: summary: /models/{model\_id} description: Updates an existing model object. If attributes are included, then the model's attributes will be replaced with the ones provided. Attributes can only be replaced if the model has no inferences. The model's attributes will remain unchanged if attributes are excluded from the request. requestBody: description: Model object to update content: application/json: schema: $ref: '#/components/schemas/ModelUpdateRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelResponse' security: - auth: [ ] tags: - models delete: summary: /models/{model\_id} description: Archives an existing model object. It will delete any compute resources for the model but will not delete inference data. The model will no longer appear in the Arthur Dashboard. responses: '204': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelResponse' security: - auth: [] tags: - models /models/{model\_id}/attributes: get: summary: /models/{model\_id}/attributes description: Returns a paginated response of a model's attributes parameters: - in: path name: model\_id schema: type: string required: true - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of attributes to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to order the attributes. By default, the attributes will be sorted by their name in asc order. Options are ['name', 'id', 'position']. To specify sort order, prepend the string with '+' for asc order and '-' for descending order, e.g. '+position' will return the attributes sorted in ascending positional order. schema: $ref: '#/components/schemas/Sort' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAttributeResponse' security: - auth: [] tags: - models put: summary: /models/{model\_id}/attributes description: Updates all of a model's attributes. If the model already has inferences, only the attribute labels and category labels can be updated. Note that this is a "put" so all attributes must be included in the request unless they should be deleted. To update a specific attribute, use the /models/{model\_id}/attributes/{attribute\_id} and to update a subset of attributes use the patch endpoint. Attribute ids should be included for attributes that already exist, otherwise we will attempt to create a new attribute. Any alert rules created for the model prior to this call will be archived. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: Array of the model attributes to update or add. content: application/json: schema: type: array items: $ref: '#/components/schemas/ModelAttributeResponse' responses: '204': description: The attributes were successfully updated. security: - auth: [] tags: - models patch: summary: /models/{model\_id}/attributes description: Updates a subset of a model's attributes. If the model already has inferences, only the attribute labels and category labels can be updated. Attribute ids should be included for attributes that already exist, otherwise we will attempt to create a new attribute. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: Array of the model attributes to update or add. Attributes in the body without an "id" are assumed to be new attributes to add to the model. content: application/json: schema: type: array items: $ref: '#/components/schemas/ModelAttributeResponse' responses: '204': description: The attributes were successfully updated. security: - auth: [] tags: - models delete: summary: /models/{model\_id}/attributes description: Deletes all of a model's attributes. Attributes can only be deleted if no inferences exist for this model. Any alert rules created for the model prior to this call will be archived. parameters: - in: path name: model\_id schema: type: string required: true responses: '204': description: Successfully deleted all attributes. security: - auth: [] tags: - models /models/{model\_id}/attributes/{attribute\_id}: get: summary: /models/{model\_id}/attributes/{attribute\_id} description: Gets the model attribute. parameters: - in: path name: model\_id schema: type: string required: true - in: path name: attribute\_id schema: type: string required: true responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelAttributeResponse' security: - auth: [] tags: - models put: summary: /models/{model\_id}/attributes/{attribute\_id} description: Updates a model attribute. If the model already has inferences then only the label and category labels can be updated. parameters: - in: path name: model\_id schema: type: string required: true - in: path name: attribute\_id schema: type: string required: true requestBody: description: The updated model attribute content: application/json: schema: $ref: '#/components/schemas/ModelAttributeResponse' responses: '200': description: The attribute was successfully updated. content: application/json: schema: $ref: '#/components/schemas/ModelAttributeResponse' security: - auth: [] tags: - models delete: summary: /models/{model\_id}/attributes/{attribute\_id} description: Deletes the model attribute. An attribute can only be deleted if the model does not have any inferences. parameters: - in: path name: model\_id schema: type: string required: true - in: path name: attribute\_id schema: type: string required: true responses: '204': description: Successfully deleted the attribute security: - auth: [] tags: - models /models/{model\_id}/reference\_data: post: summary: "/models/{model\_id}/reference\_data" description: Uploads a parquet file containing reference set data. After an initial validation, rows are uploaded asynchronously. Failed rows will result in an email alert. For image models, include images in the image\_data field of the form. See the request body schema for more details. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: Parquet file containing reference set data content: multipart/form-data: schema: $ref: '#/components/schemas/ReferenceDataRequest' responses: '207': description: multi-status response containing success, failure, and total counts and failure messages (if any) content: application/json: schema: $ref: '#/components/schemas/ParquetDataResponse' tags: - reference data get: description: Returns the reference data information for a model. parameters: - in: path name: model\_id schema: type: string required: true responses: '200': description: Reference data information for a model. content: application/json: schema: $ref: '#/components/schemas/ReferenceDatasetResponse' tags: - reference data patch: description: Closes a reference dataset. Closing transitions the dataset from "started" to "uploaded" and kicks off processing. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: Total record count for the dataset. content: application/json: schema: $ref: '#/components/schemas/ClosedRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/SuccessResponse' tags: - reference data /models/health: get: summary: /models/health description: Returns the most recent model health scores for the requested models. If the score is null and timestamp is null, it means the score has not been calculated yet for this model. If the score is null and the timestamp is not null, it means there was no data for the model from the last month for calculating a model health score. parameters: - name: model\_id in: query required: true description: A model UUID to retrieve the model health score for. Can be present in the query multiple times. schema: type: array items: + + + type: string example: 817e99b7-5792-411a-8c61-35628ec1aa80 responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ModelHealthResponse' security: - auth: [ ] tags: - models /tags: get: summary: /tags description: Get all registered tags parameters: - in: query name: page schema: $ref: '#/components/schemas/Page' - in: query name: page\_size schema: $ref: '#/components/schemas/PageSize' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedTagResponse' tags: - tags security: - auth: [] /tags/{tag\_name}: put: summary: /tags/{tag\_name} description: Update a specific tag by name. parameters: - in: path name: tag\_name schema: type: string required: true requestBody: description: Name to update specified tag with. content: application/json: schema: $ref: '#/components/schemas/TagUpdateRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/TagResponse' tags: - tags security: - auth: [] delete: summary: /tags/{tag\_name} description: Delete a specific tag by name. parameters: - in: path name: tag\_name schema: type: string required: true responses: '204': description: Success tags: - tags security: - auth: [] /alerts: get: summary: /alerts description: Returns paginated alerts. For organization-scoped users this will return alerts within their organization. For global users, this will return alerts in all organizations. parameters: - in: query name: model\_id schema: type: array items: type: string description: UUID of a model to retrieve alerts for - in: query name: metric schema: type: string description: Metric to filter alerts by. The available pre-defined metrics are (case insensitive) ['average prediction', 'psi data drift', 'psi data drift reference set', 'rmse', 'total inference count', 'total inference count by class', 'psi batch data drift reference set'] - in: query name: status schema: type: string description: status (new, acknowledged, resolved) to filter alerts on - in: query name: severity schema: type: string description: severity (critical, warning) to filter alerts on - in: query name: start\_time schema: type: string description: Find alerts that were triggered on or after this timestamp. Should be in ISO8601 string format. - in: query name: end\_time schema: type: string description: Find alerts that were triggered before this timestamp. Should be in ISO8601 string format. - in: query name: batch\_id schema: type: array items: type: string description: Batch id to filter for on alerts. - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to order the models. By default, the alerts will be sorted by their timestamp in asc order. Options are ['status', 'timestamp']. To specify sort order, prepend the string with '+' for asc order and '-' for descending order, e.g. '-timestamp' will return the models sorted in desc order by timestamp. schema: $ref: '#/components/schemas/Sort' - name: alert\_rule\_id in: query required: false description: UUID of the alert rule to filter alerts by schema: type: string responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAlertResponse' tags: - alerts security: - auth: [] /alerts/{alert\_id}: patch: summary: /alerts/{alert\_id} description: Update alert status parameters: - in: path name: alert\_id schema: type: string description: alert id of alert to update required: true requestBody: description: Update data for alert content: application/json: schema: $ref: '#/components/schemas/AlertRequest' responses: '204': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertResponse' tags: - alerts security: - auth: [] /alerts/{alert\_id}/notifications: post: description: Sends an email notification for the given alert to the configured users and integrations. parameters: - in: path name: alert\_id description: The UUID of the alert which an email notification will be generated for. This is not required, provide a random string if the notification is not associated with a specific alert id. schema: type: string format: uuid required: true - name: configuration\_id in: query required: false description: The configuration to notify on. schema: type: string format: uuid - name: manual\_trigger in: query required: false description: If this is a manual trigger, force send notification regardless of subscription status. schema: type: boolean requestBody: description: alert notification information. content: application/json: schema: $ref: '#/components/schemas/EmailNotificationBody' responses: '200': description: Success security: - api\_key: [ ] tags: - alerts /models/{model\_id}/metrics: servers: - url: https://app.arthur.ai/api/{version} variables: version: description: Metrics - v3 or v4 default: v4 enum: - v3 - v4 get: summary: /models/{model\_id}/metrics description: Fetches the stored metrics associated with this model. This may include default Arthur metrics as well as custom metrics associated with the model. parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to fetch metrics - name: page in: query required: false description: The page to fetch. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: expand in: query required: false schema: type: array items: type: string enum: - type - name: default in: query required: false schema: type: boolean description: if provided will return only metrics that are default if set to true or not defaults if set to false - name: type in: query required: false schema: type: array items: type: string enum: - model\_output\_metric - model\_input\_data\_metric - model\_performance\_metric - model\_data\_drift\_metric + + + responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedModelMetricsResponse' security: - auth: [] tags: - metrics post: summary: /models/{model\_id}/metrics description: Creates a new custom metric for the model parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to create the custom metric requestBody: content: application/json: schema: $ref: '#/components/schemas/MetricRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/MetricResponse' security: - auth: [] tags: - metrics /models/{model\_id}/metrics/{metric\_id}: servers: - url: https://app.arthur.ai/api/{version} variables: version: description: Metrics - v3 or v4 default: v4 enum: - v3 - v4 get: summary: /models/{model\_id}/metrics/{metric\_id} description: Fetches a metric by id parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to fetch metrics - in: path name: metric\_id schema: type: string required: true description: UUID of the metric to fetch responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/MetricResponse' security: - auth: [] tags: - metrics put: summary: /models/{model\_id}/metrics/{metric\_id} description: Updates a metric parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to fetch metrics - in: path name: metric\_id schema: type: string required: true description: UUID of the metric to fetch requestBody: content: application/json: schema: $ref: '#/components/schemas/MetricRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/MetricResponse' security: - auth: [] tags: - metrics delete: summary: /models/{model\_id}/metrics/{metric\_id} description: Deletes a metric. Note that if any alerts are associated with this metric then they will automatically be disabled. parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to fetch metrics - in: path name: metric\_id schema: type: string required: true description: UUID of the metric to fetch responses: '204': description: Success security: - auth: [] tags: - metrics /models/{model\_id}/metrics/{metric\_id}/result: servers: - url: https://app.arthur.ai/api/v4 post: summary: /models/{model\_id}/metrics/{metric\_id}/result description: Evaluate the metric on the provided parameters, filters, and groups parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model for which to evaluate the metric - in: path name: metric\_id schema: type: string required: true description: UUID of the metric to evaluate requestBody: content: application/json: schema: $ref: '#/components/schemas/MetricEvaluationRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/MetricEvaluationResponse' tags: - metrics + + + /models/{model\_id}/alert\_rules: get: summary: /models/{model\_id}/alert\_rules description: Retrieve a paginated list of alert rules for the specific model. parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model to get alert rules for - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 5 and the maximum is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: The column name to sort alert rules by schema: type: string - name: severity in: query required: false description: The severity type (critical, warning) to filter alert rules by schema: type: string - name: include\_alert\_metadata in: query required: false description: Whether or not to include alert metadata with each alert rule. Defaults to false. Expanded metadata includes alert counts by status, last triggered timestamp, and last triggered value. schema: type: boolean responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAlertRuleResponse' tags: - alert rules security: - auth: [] post: summary: /models/{model\_id}/alert\_rules description: Post a single alert rule for a specific model parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model to post an alert rule for requestBody: description: Alert rule to add for the model content: application/json: schema: $ref: '#/components/schemas/AlertRuleRequest' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertRuleResponse' tags: - alert rules security: - auth: [] /models/{model\_id}/alert\_rules/{alert\_rule\_id}: patch: summary: /models/{model\_id}/alert\_rules/{alert\_rule\_id} description: Update the fields included in the request for the alert rule. Note that the only fields that can be updated via this endpoint are name, bound, threshold, severity, lookback\_period, subsequent\_alert\_wait\_time, and enabled. parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model that the alert rule belongs to - in: path name: alert\_rule\_id schema: type: string required: true description: UUID of alert rule to update requestBody: description: Alert rule fields to update content: application/json: schema: $ref: '#/components/schemas/AlertRulePatch' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertRuleResponse' tags: - alert rules security: - auth: [] delete: summary: /models/{model\_id}/alert\_rules/{alert\_rule\_id} description: Archives the specified alert rule parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model that the alert rule belongs to - in: path name: alert\_rule\_id schema: type: string required: true description: UUID of alert rule to archive responses: '201': description: Success tags: - alert rules security: - auth: [] /models/{model\_id}/alert\_rules/{alert\_rule\_id}/bulk\_alerts: patch: summary: /models/{model\_id}/alert\_rules/{alert\_rule\_id}/bulk\_alerts description: Bulk update all alerts for an alert rule parameters: - in: path name: model\_id schema: type: string required: true description: UUID of the model the alert rule belongs to - in: path name: alert\_rule\_id schema: type: string required: true description: UUID of alert rule to update alerts for requestBody: description: Update data for the alerts content: application/json: schema: $ref: '#/components/schemas/AlertRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/BulkAlertUpdateResponse' tags: - alert rules security: - auth: [] /alert\_notification\_configurations: get: summary: /alert\_notification\_configurations description: Returns paginated notification configurations parameters: - in: query name: user\_id schema: type: string description: UUID of the user for which to filter notification configurations - in: query name: model\_id schema: type: string description: UUID of the model for which to filter notification configurations - name: page in: query required: false description: The page to fetch. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAlertNotificationConfigurationsResponse' tags: - alerts security: - auth: [] post: summary: /alert\_notification\_configurations description: Creates a new alert notification configuration. requestBody: description: The new alert notification configuration to create content: application/json: schema: $ref: '#/components/schemas/NewAlertNotificationConfiguration' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertNotificationConfiguration' tags: - alerts security: - auth: [] /alert\_notification\_configurations/{configuration\_id}: parameters: - in: path name: configuration\_id schema: type: string required: true description: id of the alert notification configuration get: summary: /alert\_notification\_configurations/{configuration\_id} description: Returns an alert notification configuration responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertNotificationConfiguration' tags: - alerts security: - auth: [] patch: summary: /alert\_notification\_configurations/{configuration\_id} description: Updates an alert notification configuration. requestBody: description: The configuration fields to update content: application/json: schema: $ref: '#/components/schemas/AlertNotificationConfigurationUpdate' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertNotificationConfiguration' tags: - alerts security: - auth: [] delete: summary: /alert\_notification\_configurations/{configuration\_id} description: Deletes an alert notification configuration. responses: '204': description: Successfully deleted the alert notification configuration tags: - alerts security: - auth: [] /models/{model\_id}/inferences: parameters: - in: path name: model\_id schema: type: string required: true description: id of the model that the inferences belong to post: summary: /models/{model\_id}/inferences description: Saves new inferences requestBody: description: The inferences to ingest content: application/json: schema: $ref: '#/components/schemas/NewInferences' responses: '207': description: Success content: application/json: schema: $ref: '#/components/schemas/InferencesResponse' tags: - inferences security: - auth: [] patch: summary: /models/{model\_id}/inferences description: Updates inferences with ground truth data requestBody: description: The inferences' ground truth data content: application/json: schema: $ref: '#/components/schemas/InferencesGroundTruth' responses: '207': description: Success content: application/json: schema: $ref: '#/components/schemas/InferencesResponse' tags: - inferences security: - auth: [] /models/{model\_id}/inferences/file: parameters: - in: path name: model\_id schema: type: string required: true description: id of the model that the inferences belong to post: summary: /models/{model\_id}/inferences/file description: Uploads a parquet file containing inferences or a parquet file containing ground truth. Either inference\_data or ground\_truth\_data must be included in the request. After an initial validation, inferences are uploaded asynchronously. Failed inferences will result in an email alert. For image models, include images in the image\_data field of the form. See the request body schema for more details. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: File of inferences and optional batch id or file of ground truth content: multipart/form-data: schema: $ref: '#/components/schemas/FileInferenceData' responses: '207': description: Success content: application/json: schema: $ref: '#/components/schemas/ParquetDataResponse' tags: - inferences security: - auth: [] /models/{model\_id}/inferences/integrations/sagemaker\_data\_capture: parameters: - in: path name: model\_id schema: type: string required: true description: id of the model that the inferences belong to post: summary: /models/{model\_id}/inferences/integrations/sagemaker\_data\_capture description: Accepts a SageMaker Data Capture JSONL file containing inferences. The form-data key "inference\_data" must be included in the request and map to a SageMaker Data Capture file. After an initial validation, inferences are uploaded asynchronously. Failed inferences will result in an email alert. See the request body schema for more details. parameters: - in: path name: model\_id schema: type: string required: true requestBody: description: File of inference. content: multipart/form-data: schema: $ref: '#/components/schemas/SageMakerInferenceData' responses: '207': description: Success content: application/json: schema: $ref: '#/components/schemas/SageMakerDataResponse' tags: - inferences security: - auth: [ ] /models/{model\_id}/inferences/images/{image\_id}: parameters: - in: path name: model\_id schema: type: string required: true description: id of the model that the inferences belong to - in: path name: image\_id schema: type: string required: true description: the Arthur-generated id for the image, can be found in the Image type attribute of CV inferences get: summary: /models/{model\_id}/inferences/images/{image\_id} description: Retrieve inference image files. Type=raw\_image will return the original uploaded image. Type=resized\_image will return the image resized to your model's input size. Type=thumbnail will return a thumbnail sized version of the image. Type=lime\_explanation will return a JSON file of lime region mapping and lime segment mask. parameters: - in: query name: type schema: type: string enum: - raw\_image - resized\_image - thumbnail - lime\_explanation required: true responses: '307': description: Redirect to download URL content: text/plain: schema: type: string tags: - inferences security: - auth: [ ] /models/{model\_id}/inferences/{partner\_inference\_id}/explanation: get: summary: /models/{model\_id}/inferences/{partner\_inference\_id}/explanation description: Fetches an on-demand inference explanation. Each time this endpoint is called a new explanation for the given inferences is generated. parameters: - in: path name: model\_id schema: type: string required: true description: id of the model that the inference belongs to - in: path name: partner\_inference\_id schema: type: string required: true description: The pre-defined, user generated unique id associated with the inference - in: query name: algorithm schema: type: string default: lime required: false description: The algorithm to use to generate explainability, options are [lime, shap] - in: query name: n\_samples schema: type: integer required: false description: Number of samples to use when generating the explanation. For SHAP, this corresponds to the 'nsamples' parameter and for LIME, this corresponds to 'num\_samples'. If this is not provided, then we will use the value configured via the model explanation endpoint. - name: page in: query required: false description: The page to fetch. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of explanations to return in a single page. The default is 500, this is mainly utilized for models with many attributes or NLP models. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: Tells us how to order the explanations. By default, explanations will be sorted asc by their explanation value. Options vary by model type. For NLP models the available options are ['value', 'word', 'location']. For tabular models the options are ['attribute\_name', 'value']. To specify sort order, prepend the string with '+' for asc order and '-' for descending order, e.g. '+word' will return the explanations sorted by word in alphabetical order. schema: $ref: '#/components/schemas/Sort' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ExplainabilityResultOnDemand' security: - auth: [] tags: - explainability /models/{model\_id}/what\_if: post: summary: "/models/{model\_id}/what\_if" description: "Retrieve the prediction and explanation for an inference. Only valid for models with input type equal to Tabular." parameters: - in: path name: model\_id schema: type: string required: true description: id of the model to get an explanation for requestBody: description: Inference to get what-if values for content: application/json: schema: $ref: '#/components/schemas/WhatIfRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ExplainabilityResultWhatIf' security: - auth: [] tags: - explainability /models/{model\_id}/inferences/query: post: summary: /models/{model\_id}/inferences/query description: This endpoint takes a query request in the body and returns inferences and metrics for the model's inferences. Please see the "Query Guide" linked above for more information. parameters: - in: path name: model\_id schema: type: string required: true description: The id of the model for which to query inferences - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. schema: $ref: '#/components/schemas/PageSize' requestBody: description: The query to perform on the inferences content: application/json: schema: $ref: '#/components/schemas/QueryRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/QueryResult' tags: - query /models/{model\_id}/inferences/query/data\_drift: post: summary: /models/{model\_id}/inferences/query/data\_drift description: This endpoint takes a data drift query request and returns data drift values. For example queries, see the "Query Guide" under the API section. parameters: - in: path name: model\_id schema: type: string required: true description: The id of the model for which to query inferences requestBody: description: The query to perform on the inferences content: application/json: schema: $ref: '#/components/schemas/DataDriftRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DataDriftResponse' tags: - query /models/{model\_id}/inferences/query/data\_drift\_psi\_bucket\_calculation\_table: post: summary: /models/{model\_id}/inferences/query/data\_drift\_psi\_bucket\_calculation\_table description: This endpoint takes a data drift table query request and returns raw psi bucket values. For example queries, see the "Query Guide" under the API section. parameters: - in: path name: model\_id schema: type: string required: true description: The id of the model for which to query inferences requestBody: description: The query to perform on the inferences content: application/json: schema: $ref: '#/components/schemas/DataDriftTableRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DataDriftTableResponse' tags: - query /models/{model\_id}/inferences/query/distributions: post: summary: /models/{model\_id}/inferences/query/distributions description: This endpoint takes in attributes that should correspond to x and y values and optional additional values and filters and returns scatterplot data. It buckets the x attribute, then buckets the y attribute and returns the values specified in the request that fall within each bucket. parameters: - in: path name: model\_id schema: type: string required: true description: The id of the model for which to query inferences requestBody: description: The attributes and values to return in the bucketed distributions content: application/json: schema: $ref: '#/components/schemas/DistributionsRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/QueryResult' example: query\_result: - AGE: 30.76 BILL\_AMT1: 79957.25 BILL\_AMT2: 155635.4 count: 84 - AGE: 39.31 BILL\_AMT1: 194275.55 BILL\_AMT2: -6663.799999999996 count: 254 - AGE: 37 BILL\_AMT1: 270487.75 BILL\_AMT2: 33911.00000000001 count: 46 tags: - query /models/{model\_id}/datasets: parameters: - in: path name: model\_id schema: type: string required: true get: description: Retrieve all datasets for a model responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/DatasetsResponse' tags: - inferences /models/{model\_id}/batches/{batch\_id}: get: description: Returns the batch information for a model. parameters: - in: path name: model\_id schema: type: string required: true - in: path name: batch\_id schema: type: string required: true responses: '200': description: Batch information for a model. content: application/json: schema: $ref: '#/components/schemas/BatchResponse' tags: - inferences patch: description: Closes a batch. Closing transitions the dataset from "started" to "uploaded" and kicks off processing. parameters: - in: path name: model\_id schema: type: string required: true - in: path name: batch\_id schema: type: string required: true requestBody: description: Total record count for the dataset. content: application/json: schema: $ref: '#/components/schemas/ClosedRequest' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/SuccessResponse' tags: - inferences /models/{model\_id}/enrichments/bias\_mitigation/curves: get: description: Retrieve Bias Mitigation curves for a specified model and query parameters. parameters: - in: path name: model\_id schema: type: string required: true - in: query name: attribute\_id schema: type: string required: false - name: constraint in: query required: false description: constraint to filter for. schema: type: array items: type: string enum: - demographic\_parity - equal\_opportunity - equalized\_odds example: equal\_opportunity - name: attribute\_value in: query required: false description: attribute\_value to filter for. schema: type: array items: type: string - name: continuous\_value in: query required: false description: Continuous value range to filter curves by. A range should be a string starting with the string representation of the start index followed by two underscores and then the string representation of the end index (`{start\_index}\_\_{end\_index}`). To denote open ended ranges use the keyword `none` (`none\_\_18`, represents the range less than 18). schema: type: array items: type: string - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of mitigation curves to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' responses: '200': description: Success. content: application/json: schema: $ref: '#/components/schemas/PaginatedBiasMitigationCurves' tags: - enrichments /models/{model\_id}/enrichments: parameters: - in: path name: model\_id schema: type: string required: true get: summary: /models/{model\_id}/enrichments description: Gets the enrichment configurations for a model responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/EnrichmentsConfiguration' tags: - enrichments patch: summary: /models/{model\_id}/enrichments description: Updates the enrichment configuration for a model requestBody: description: The enrichment configurations content: multipart/form-data: schema: $ref: '#/components/schemas/EnrichmentsRequest' encoding: configuration: contentType: application/json responses: '202': description: The status of each enrichment # content: # application/json: # schema: # $ref: '#/components/schemas/EnrichmentsStatus' tags: - enrichments + + + /models/{model\_id}/enrichments/anomaly\_detection: parameters: - in: path name: model\_id schema: type: string required: true get: summary: /models/{model\_id}/enrichments/anomaly\_detection responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AnomalyDetectionEnrichmentResponse' tags: - enrichments patch: summary: /models/{model\_id}/enrichments/anomaly\_detection description: Enable or disable anomaly\_detection for a model requestBody: description: Anomaly Detection configuration content: application/json: schema: $ref: '#/components/schemas/AnomalyDetectionEnrichmentConfiguration' responses: '202': description: Success # content: # application/json: # schema: # $ref: '#/components/schemas/EnrichmentStatus' tags: - enrichments + + + /models/{model\_id}/enrichments/bias\_mitigation: parameters: - in: path name: model\_id schema: type: string required: true get: summary: /models/{model\_id}/enrichments/bias\_mitigation responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/BiasMitigationEnrichmentResponse' tags: - enrichments patch: summary: /models/{model\_id}/enrichments/bias\_mitigation description: Enable or disable bias\_mitigation for a model requestBody: description: Bias Mitigation configuration content: application/json: schema: $ref: '#/components/schemas/BiasMitigationEnrichmentConfiguration' responses: '202': description: Success # content: # application/json: # schema: # $ref: '#/components/schemas/EnrichmentStatus' tags: - enrichments + + + /models/{model\_id}/enrichments/hotspots: parameters: - in: path name: model\_id schema: type: string required: true get: summary: /models/{model\_id}/enrichments/hotspots responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/HotspotsEnrichmentResponse' tags: - enrichments patch: summary: /models/{model\_id}/enrichments/hotspots description: Enable or disable hotspots for a model requestBody: description: Hotspots configuration content: application/json: schema: $ref: '#/components/schemas/HotspotsEnrichmentConfiguration' responses: '202': description: Success # content: # application/json: # schema: # $ref: '#/components/schemas/EnrichmentStatus' tags: - enrichments + + + /models/{model\_id}/enrichments/hotspots/find: get: summary: /models/{model\_id}/enrichments/hotspots/find description: Find hotspots for a model using the given metric and threshold. For batch models, supply batch\_id, for streaming models, supply a date. Cannot supply both date and batch. parameters: - in: path name: model\_id schema: type: string required: true - in: query name: date schema: type: string description: The date to find hotspots for. Only applies to streaming models. Results will be returned for a full week containing the provided date. - in: query name: batch\_id schema: type: string description: The batch to find hotspots for. Only applies to batch models. - in: query name: metric schema: type: string required: true description: The metric used to evaluate hotspots. Options are [accuracy | recall | f1 | precision]. - in: query name: threshold schema: type: number required: true description: The threshold to compare the metric against. Areas that are below this value for the given metric are deemed hotspots. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/FindHotspotsResponse' tags: - enrichments + + + /models/{model\_id}/enrichments/explainability: parameters: - in: path name: model\_id schema: type: string required: true get: summary: /models/{model\_id}/enrichments/explainability responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/ExplainabilityEnrichmentResponse' tags: - enrichments patch: summary: /models/{model\_id}/enrichments/explainability description: Configure explainability for a model requestBody: description: Explainability configuration and artifacts. content: multipart/form-data: schema: $ref: '#/components/schemas/ExplainabilityEnrichmentRequest' responses: '202': description: Success # content: # application/json: # schema: # $ref: '#/components/schemas/EnrichmentStatus' tags: - enrichments + + + /usage/{rollup}: parameters: - in: query name: metric\_category description: Metric categories to have populated in the response. Organizational metrics can only be returned with rollup type `organization`. At least one metric category must be selected. schema: type: array items: $ref: '#/components/schemas/UsageCategory' required: true - in: query name: start\_time schema: type: string description: Optional, inclusive start date in ISO8601 string format. Defaults to the first timestamp of the current month if not provided. - in: query name: end\_time schema: type: string description: Optional, exclusive end date in ISO8601 string format. Defaults to the first timestamp of next month if not provided. - in: path name: rollup schema: $ref: '#/components/schemas/UsageRollups' required: true description: The level to aggregate the metrics. Results will be aggregated on objects within the user's current authenticated session. For example, an organization scoped user calling this endpoint with a rollup by model will group by all models in the user's current organization. For that user, a rollup of `organization` will only return a single object under the data array. For a global scoped user with model rollup, a block will be returned for every model in every organization. Similarly for a global scoped user with organization rollup, one block will be returned for each organization. get: summary: Get usage metrics. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedUsageResponse' tags: - usage + + + /alert\_summary\_configurations: get: parameters: - name: page in: query required: false description: The page to fetch. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' summary: /alert\_summary\_configurations description: Returns paginated alert summary configurations for the requesting user's organization responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAlertSummaryConfigurationsResponse' tags: - alert-summary security: - auth: [] post: summary: /alert\_summary\_configurations description: Creates a new alert summary configuration. requestBody: description: The new alert summary configuration to create content: application/json: schema: $ref: '#/components/schemas/NewAlertSummaryConfiguration' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryConfiguration' tags: - alert-summary security: - auth: [] + + + /alert\_summary\_configurations/{configuration\_id}: parameters: - name: configuration\_id in: path required: true description: id of the alert summary configuration schema: type: string get: summary: /alert\_summary\_configurations/{configuration\_id} description: Returns the alert summary configuration responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryConfiguration' tags: - alert-summary security: - auth: [] patch: summary: /alert\_summary\_configurations/{configuration\_id} description: Updates an alert summary configuration. requestBody: description: Alert Summary Configuration to update content: application/json: schema: $ref: '#/components/schemas/AlertSummaryConfigurationUpdate' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryConfiguration' tags: - alert-summary security: - auth: [] delete: summary: /alert\_summary\_configurations/{configuration\_id} description: Deletes an alert summary configuration. responses: '204': description: Successfully deleted the alert summary configuration tags: - alert-summary security: - auth: [] + + + /alert\_summary\_configurations/{configuration\_id}/subscribers: parameters: - name: configuration\_id in: path required: true description: id of the alert summary configuration schema: type: string get: summary: /alert\_summary\_configurations/{configuration\_id}/subscribers description: Returns a collection of subscribers of an alert summary responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedAlertSummaryNotificationConfigurationsResponse' tags: - alert-summary security: - auth: [ ] post: summary: /alert\_summary\_configurations/{configuration\_id}/subscribers description: Creates a new subscriber of an alert summary requestBody: description: The new subscriber to create content: application/json: schema: $ref: '#/components/schemas/NewAlertSummaryNotificationConfiguration' responses: '201': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryNotificationConfiguration' security: - auth: [ ] tags: - alert-summary + + + /alert\_summary\_configurations/{configuration\_id}/subscribers/{subscriber\_id}: parameters: - name: configuration\_id in: path required: true description: id of the alert summary configuration schema: type: string - name: subscriber\_id in: path required: true description: id of the alert summary notification configuration of an alert summary schema: type: string get: summary: /alert\_summary\_configurations/{configuration\_id}/subscribers/{subscriber\_id} description: Returns the notification configuration for a subscriber of an alert summary responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryNotificationConfiguration' tags: - alert-summary security: - auth: [ ] patch: summary: /alert\_summary\_configurations/{configuration\_id}/subscribers/{subscriber\_id} description: Updates the notification configuration of a subscriber of an alert summary. requestBody: description: Alert Summary Notification Configuration to update content: application/json: schema: $ref: '#/components/schemas/AlertSummaryNotificationConfigurationUpdate' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/AlertSummaryNotificationConfiguration' tags: - alert-summary security: - auth: [ ] delete: summary: /alert\_summary\_configurations/{configuration\_id}/subscribers/{subscriber\_id} description: Deletes the notification configuration for a subscriber of an alert summary. responses: '204': description: Successfully deleted the alert summary notification configuration tags: - alert-summary security: - auth: [ ] + + + /insights/model\_counts: parameters: - name: status in: query required: false description: The status type (new, acknowledged, resolved) to filter insights by. schema: type: string - name: start\_time in: query required: false description: Count insights that were created on or after this timestamp. Should be in ISO8601 string format. schema: type: string - name: end\_time in: query required: false description: Count insights that were created before this timestamp. Should be in ISO8601 string format. schema: type: string get: summary: /insights/model\_counts description: Retrieves insight counts by model id for all active models in the current organization. If a model has no insights that fit the search criteria, the model\_id will not be included in the response. responses: '200': description: Success content: application/json: schema: type: array items: $ref: '#/components/schemas/ModelInsightCount' tags: - insights /models/{model\_id}/insights: parameters: - name: model\_id in: path required: true description: UUID of the model the insights belong to schema: type: string get: summary: /models/{model\_id}/insights description: Retrieve a paginated list of insights for the specific model. parameters: - name: page in: query required: false description: The page to fetch. Will default to 1. schema: $ref: '#/components/schemas/Page' - name: page\_size in: query required: false description: The number of objects to return in a single page. The default is 20. schema: $ref: '#/components/schemas/PageSize' - name: sort in: query required: false description: The column name and direction to sort insights by. Will default to +timestamp. schema: type: string - name: start\_time in: query required: false schema: type: string description: Find insights that were created on or after this timestamp. Should be in ISO8601 string format. - name: end\_time in: query required: false schema: type: string description: Find insights that were created before this timestamp. Should be in ISO8601 string format. - name: status in: query required: false description: The status type (new, acknowledged, resolved) to filter insights by. schema: type: string - name: batch\_id in: query required: false description: The batch\_id to return insights for. schema: type: string responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PaginatedInsights' tags: - insights patch: summary: /models/{model\_id}/insights description: Update the status of the insights for a specific model requestBody: description: Update information for insights content: application/json: schema: $ref: '#/components/schemas/InsightPatch' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/InsightUpdateResponse' tags: - insights + + + /models/{model\_id}/insights/{insight\_id}: get: summary: /models/{model\_id}/insights/{insight\_id} description: Retrieve insight for the specific model and insight id. responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/Insight' tags: - insights patch: summary: /models/{model\_id}/insights/{insight\_id} description: Update the status of the insight for a specific model and insight id. requestBody: description: Update information for insight content: application/json: schema: $ref: '#/components/schemas/InsightPatch' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/InsightUpdateResponse' tags: - insights /authorization/authorize: post: summary: /authorization/authorize description: Endpoint for validating a requesting caller has the permissions on the supplied action and resource requestBody: description: Action and Resource the request is asking to authorize content: application/json: schema: $ref: '#/components/schemas/PermissionRequest' responses: '200': description: Allowed '403': description: Forbidden tags: - authorization /authorization/permissions: get: summary: /authorization/permissions description: Endpoint that returns all permissions for the requesting caller. Will return an empty list if the caller has no permissions in the current organization. responses: '200': description: Success content: application/json: schema: type: array items: $ref: '#/components/schemas/PermissionRequest' tags: - authorization + + + /authorization/custom\_roles: get: summary: /authorization/custom\_roles description: Returns custom defined roles for the calling organization parameters: - name: roles in: query required: false description: A comma separated list of roles. If specified, returns the role definitions for these roles in the current organization. If not specified, returns role definitions for all roles. schema: type: string responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/CustomRBACRequest' tags: - authorization post: summary: /authorization/custom\_roles description: Create custom defined roles for the calling organization. If roles exist for this org already, this request will be additive requestBody: description: A list defining each custom role, it's permissions, and any roles it inherits permissions from content: application/json: schema: $ref: '#/components/schemas/CustomRBACRequest' responses: '200': description: All custom defined roles for the calling organization content: application/json: schema: $ref: '#/components/schemas/CustomRBACRequest' tags: - authorization delete: summary: /authorization/custom\_roles description: Delete any or all custom roles defined for the calling organization requestBody: description: A comma separated list of roles to delete. Passing "\*" as one of the roles will delete all roles for the organization. content: application/json: schema: $ref: '#/components/schemas/RolesRequest' responses: '200': description: All remaining custom defined roles for the calling organization after the delete was successful content: application/json: schema: $ref: '#/components/schemas/CustomRBACRequest' tags: - authorization + + + components: securitySchemes: auth: type: apiKey in: header name: Authorization schemas: UsageRollups: type: string enum: - organization - model UsageCategory: enum: - inferences - explanations - organization - ground\_truth - reference\_data UsageMetric: required: - name - value properties: name: description: 'Name of the metric. For inferences, explanations, and ground\_truth this will be either bytes or record\_count. For organizational metrics this will be user\_count and/or model\_count.' type: string example: record\_counts value: type: number UsageData: required: - metrics - id - name - organization\_id properties: inferences: type: array items: $ref: '#/components/schemas/UsageMetric' explanations: type: array items: $ref: '#/components/schemas/UsageMetric' organization: type: array items: $ref: '#/components/schemas/UsageMetric' ground\_truth: type: array items: $ref: '#/components/schemas/UsageMetric' id: type: string format: uuid example: 19e2716a-02a0-4b52-9ff2-540c1e685be6 description: When rollup = "model", this will be the model id. When rollup = "organization", this will be the organization id. name: type: string example: "Model A" organization\_id: type: string format: uuid example: dc355b20-9163-4619-a0b8-4bf2cd8d62d7 description: In the case where rollup = "model", this will be the organization id for the model referenced by "id". In the case where rollup = "organization", this will be the same value as the "id" field. PaginatedUsageResponse: required: - data - total\_count - rollup - interval\_start - interval\_end properties: data: type: array items: $ref: '#/components/schemas/UsageData' total\_count: type: integer rollup: type: string example: "model" interval\_start: type: string format: date-time interval\_end: type: string format: date-time + + + DistributionsRequest: required: - x - y properties: x: $ref: '#/components/schemas/DistributionsAttribute' y: $ref: '#/components/schemas/DistributionsAttribute' values: type: array items: $ref: '#/components/schemas/DistributionValue' filter: $ref: '#/components/schemas/QueryFilters' example: x: property: "BILL\_AMT1" num\_bins: 20 y: property: "BILL\_AMT2" num\_bins: 20 values: - function: "count" alias: "count" - function: "avg" property: "AGE" filter: - property: "AGE" comparator: "gte" value: 25 DistributionsAttribute: required: - property properties: property: type: string description: The name of the property to select. This can be the name of any attribute associated with the model. alias: type: string description: If an alias is provided, this will be returned as the name for the associated result. num\_bins: type: number description: The number of "buckets" to distribute the attribute into. Value must be at least 2 and no greater than 200. If not specified, we will default to 20. DistributionValue: properties: function: type: string description: optional, an aggregation function like count, sum, abs, max, min, avg property: type: string description: The name of the property to select. This can be the name of any attribute associated with the model. alias: type: string description: If an alias is provided, this will be returned as the name for the associated result. QueryRequest: required: - select properties: select: $ref: '#/components/schemas/QuerySelect' from: type: string description: "Data to query. Inferences are the raw inferences sent to the platform. Enriched includes the raw inferences, plus enriched properties like explanations and anomaly scores. Reference is the reference data set uploaded to the platform. The default is 'inference'." enum: - inference - enriched - reference subquery: $ref: '#/components/schemas/QueryRequest' filter: $ref: '#/components/schemas/QueryFilters' group\_by: $ref: '#/components/schemas/QueryGroupBy' order\_by: $ref: '#/components/schemas/QueryOrderBy' QuerySelect: type: array items: $ref: '#/components/schemas/QuerySelectItem' QuerySelectItem: description: Describes the fields and functions the query should return properties: function: type: string description: The name of the function to use. Either property or function can be specified but not both. enum: - avg - max - min - count - roundTimestamp - labelByMaxColumn - binContinuous - distribution - classificationAccuracyRate - rate - rmse - binsToQuantiles property: type: string description: The name of the property to select. This can be the name of any attribute associated with the model, any of the enriched attributes ['anomaly\_score', 'lime\_feature\_importance', 'shap\_feature\_importance'], or "\*", which selects all of the model's non-enriched attributes. Either property or function can be specified but not both. alias: type: string description: If an alias is provided, this will be returned as the name for the associated result. By default, functions will have the alias set to the function name unless one is provided. parameters: $ref: '#/components/schemas/SelectParameter' SelectParameter: description: Some functions will require additional parameters, for example, you will want to specify the "threshold" for the count function for a classifier. See the Query Documentation for more details type: object additionalProperties: anyOf: - type: number - type: string - type: boolean - $ref: '#/components/schemas/AnyArray' - $ref: '#/components/schemas/KeyValueObject' - $ref: '#/components/schemas/NestedParameterReference' NestedParameterReference: description: Can be used in a function parameter to refer to a column by alias or nest another function as input. Only one of nested\_function or alias\_ref can be specified at a time. type: object properties: nested\_function: $ref: '#/components/schemas/QuerySelectItem' alias\_ref: type: string description: references another alias column by name QueryFilters: type: array items: $ref: '#/components/schemas/QueryFilter' QueryFilter: required: - comparator - value properties: property: type: string description: The name of the property to filter on. This field is required if alias is not provided. alias: type: string description: This will map back to a defined function in the select field and allows you to filter on a calculated function. Required if property is not provided. comparator: type: string description: gt = greater than, gte = greater than or equal, lt = less than, lte = less than or equal, eq = equal, like = used for text search enum: [gt, gte, lt, lte, eq, in, like] value: description: The value to compare the property against oneOf: - type: integer - type: number - type: string QueryGroupBy: type: array items: $ref: '#/components/schemas/QueryGroupByItem' QueryOrderBy: type: array items: $ref: '#/components/schemas/QueryOrderByItem' AnyArray: type: array items: oneOf: - type: integer - type: number - type: string - $ref: '#/components/schemas/KeyValueObject' QueryGroupByItem: properties: property: type: string description: This will be the name of one of the model's attributes or an enriched attribute. Required if alias is not provided. alias: type: string description: This should map back to an alias defined in the select clause. Required if property is not provided. QueryOrderByItem: properties: property: type: string description: This will be the name of one of the model's attributes or an enriched attribute. Required if alias is not provided. alias: type: string description: This should map back to an alias defined in the select clause. Required if property is not provided. direction: type: string description: Either 'asc' or 'desc'. Defaults to 'asc'. QueryResult: required: - query\_result properties: query\_result: type: array items: $ref: '#/components/schemas/ResultRow' DataDriftRequest: required: - properties - metric - base - target properties: properties: type: array items: type: string description: This is a list of model attributes or an enriched attributes. At least one is required. num\_bins: type: integer description: "Continuous attributes only - Sets the number of bins in which to perform the data drift calculation. Bin boundaries are created by assigning each data point of the continuous property to 1 of [numBins] quantiles. For example: If you have an attribute of 100 values from 1 to 100, and passed numBins = 10, then 10 bins would be created with boundaries at 10, 20, 30, ..., 100" metric: type: string enum: - KLDivergence - PSI - JSDivergence - HellingerDistance - NLPDataDrift - HypothesisTest - Multivariate description: A required parameter that will determine type of data drift value. base: $ref: '#/components/schemas/DataDriftRequestBase' target: $ref: '#/components/schemas/DataDriftRequestBase' group\_by: $ref: '#/components/schemas/QueryGroupBy' rollup: type: string enum: - minute - hour - day - month - year - batch\_id description: An optional parameter that will aggregate the calculated data drift value by the supported dimension. DataDriftRequestBase: properties: source: type: string enum: - inference - reference description: Location of the data (inference or reference) filter: $ref: '#/components/schemas/QueryFilters' DataDriftTableRequest: required: - property - base - target properties: property: type: string description: This will be the name of one of the model's attributes or an enriched attribute. Required if alias is not provided. num\_bins: type: integer description: "Continuous attributes only - Sets the number of bins in which to perform the (PSI)[https://scholarworks.wmich.edu/cgi/viewcontent.cgi?article=4249&context=dissertations] calculation. Bin boundaries are created by assigning each data point of the continuous property to 1 of [numBins] quantiles. For example: If you have an attribute of 100 values from 1 to 100, and passed numBins = 10, then 10 bins would be created with boundaries at 10, 20, 30, ..., 100" base: $ref: '#/components/schemas/DataDriftRequestBase' target: $ref: '#/components/schemas/DataDriftRequestBase' group\_by: $ref: '#/components/schemas/QueryGroupBy' rollup: type: string enum: - minute - hour - day - month - year - batch\_id description: An optional parameter that will aggregate the calculated PSI value by the supported dimension. DataDriftTableResponse: properties: query\_result: type: array items: $ref: '#/components/schemas/PSIBucketValue' PSIBucketValue: properties: bucket: type: string rollup: type: string enum: - minute - hour - day - month - year - batch\_id group\_by\_property: type: string base\_bucket\_max: type: number base\_bucket\_min: type: number base\_count\_per\_bucket: type: number base\_ln\_probability\_per\_bucket: type: number base\_probability\_per\_bucket: type: number base\_total: type: number target\_bucket\_max: type: number target\_bucket\_min: type: number target\_count\_per\_bucket: type: number target\_ln\_probability\_per\_bucket: type: number target\_probability\_per\_bucket: type: number target\_total: type: number probability\_difference: type: number ln\_probability\_difference: type: number psi: type: number DataDriftResponse: properties: query\_result: type: array items: $ref: '#/components/schemas/PsiValue' PsiValue: properties: rollup: type: string enum: - minute - hour - day - month - year - batch\_id group\_by\_property: type: string psi\_value: type: number ResultRow: description: Represents 1 row of result data type: object additionalProperties: anyOf: - type: number - type: string - type: boolean - $ref: '#/components/schemas/KeyValueObject' KeyValueObject: type: object additionalProperties: anyOf: - type: number - type: string - type: boolean Page: type: integer default: 1 PageSize: type: integer example: 100 TotalPages: description: The number of result pages that this query generated, the ceiling of the total number of results divided by the page size type: integer example: 1 TotalCount: description: The total number of results the query returned type: integer example: 2 Sort: type: string description: Must be supplied in the format [column\_name] to denote asc sort by this column OR -[column\_name] to denote desc sort by this column Stage: type: string description: Stage of this attribute in the model pipeline. PREDICT\_FUNCTION\_INPUT is deprecated, use PIPELINE\_INPUT instead. example: GROUND\_TRUTH enum: - GROUND\_TRUTH - GROUND\_TRUTH\_CLASS - NON\_INPUT\_DATA - PIPELINE\_INPUT - PREDICTED\_VALUE - PREDICT\_FUNCTION\_INPUT PaginatedAttributeResponse: required: - data - page - page\_size properties: data: type: array description: List of model objects. items: $ref: '#/components/schemas/ModelAttributeResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' PaginatedUsers: required: - data - page - page\_size properties: data: type: array description: List of users. items: $ref: '#/components/schemas/User' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' PaginatedModelResponse: required: - data - page - page\_size properties: data: type: array description: List of model objects. items: $ref: '#/components/schemas/ModelResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' ModelObject: required: - id - input\_type - output\_type - partner\_model\_id - created\_by properties: id: type: string description: The auto-generated unique UUID for the model. display\_name: type: string description: An optional display name for the model. maxLength: 255 partner\_model\_id: type: string description: Client provided unique id to associate with the model. This field must be unique across all active models and cannot be changed once set! maxLength: 255 description: type: string description: Optional description of the model. maxLength: 255 input\_type: type: string description: The type of the model's input data. example: TABULAR enum: - IMAGE - TABULAR - NLP output\_type: type: string description: The output type of the model. example: MULTILABEL enum: - MULTICLASS - MULTILABEL - REGRESSION is\_batch: type: boolean description: Boolean value to determine whether the model sends inferences in batch or streaming format. Defaults to False. example: False archived: type: boolean description: Indicates whether or not a model has been archived, defaults to false. created\_at: type: string format: date-time description: UTC timestamp in ISO8601 format of when the model was created. updated\_at: type: string format: date-time description: UTC timestamp in ISO8601 format of when the model was last updated. attributes: type: array description: Attribute definitions for the model. Included only if the query param 'expand=attributes' is present. minItems: 1 items: $ref: '#/components/schemas/ModelAttributeResponse' tags: type: array description: Keywords to associate with the model. items: type: string classifier\_threshold: type: number description: 'Threshold value for classification models, default is 0.5.' text\_delimiter: type: string description: Only valid for models with `input\_type` equal to `NLP`. Represents the text delimiter to divide input strings. example: "," status: type: string description: The on-boarding status of the model. example: Ready enum: - Pending - Provisioning - Ready - Failed - Unknown - Archived created\_by: $ref: '#/components/schemas/CreatedBy' ModelResponse: required: - explainability - model\_group\_name - total\_inference\_count - average\_inference\_count - last\_inference\_timestamp - health\_score - critical\_alert\_count allOf: - $ref: '#/components/schemas/ModelObject' properties: explainability: $ref: '#/components/schemas/ExplainabilityResponse' model\_group\_name: type: string description: The name of the model group the model belongs to. total\_inference\_count: type: number description: The total number of inferences uploaded for the model. average\_inference\_count: type: number description: The average of the daily inference counts for the model over the last month. last\_inference\_timestamp: type: string description: The timestamp of the last inference for the model. health\_score: type: number description: The aggregated health score of the model between 0-100. For details see Arthur Docs. example: 78.9823 accuray\_health\_score: type: number description: The health score of the model accuracy between 0-100. For details on how the score is calculated see Arthur Docs. example: 86.5 drift\_health\_score: type: number description: The health score of the model's data drift between 0-100. For details on how the score is calculated see Arthur Docs. example: 90.076 ingestion\_health\_score: type: number description: The health score of the model's data ingestion between 0-100. For details on how the score is calculated see Arthur Docs. example: 76.976 critical\_alert\_count: type: number description: The total number of critical alerts for the model that are active (status is new or acknowledged). CreatedBy: description: Contains the information about an entity. required: - type - id properties: id: type: string description: ID of the entity type: type: string description: What kind of entity does the ID represent. enum: - service-account - arthur-managed - idp-managed LoginRequest: required: - login - password properties: login: type: string description: either an email or a username password: type: string ModelAttributeResponse: description: A model attribute. Note that an attribute can only have categories if it is categorical and bins if it is not categorical, it can never have both. required: - id - name - value\_type - stage - categorical - monitor\_for\_bias - is\_unique - is\_positive\_predicted\_attribute - is\_implicit properties: id: type: string description: Auto-generated unique UUID for the attribute. name: type: string description: Name of the attribute. maxLength: 255 label: type: string description: Label for attribute. If attribute has an encoded name, a more readable label can be set. maxLength: 255 value\_type: type: string description: Attribute value type. example: BOOLEAN enum: - BOOLEAN - FLOAT - IMAGE - INTEGER - STRING - TIMESTAMP - UNSTRUCTURED\_TEXT stage: $ref: '#/components/schemas/Stage' position: type: integer description: The array position of attribute within the stage. Required in the `PIPELINE\_INPUT` stage. minimum: 0 example: 0 categorical: type: boolean description: Flag that indicates whether or not this attribute is categorical. default: false min\_range: description: Optional field that indicates the minimum attribute value. oneOf: - type: integer - type: number max\_range: description: Optional field that indicates the maximum attribute value. oneOf: - type: integer - type: number monitor\_for\_bias: type: boolean description: Indicates whether this attribute should be included in bias tracking. default: false categories: type: array description: If the attribute is categorical, this will contain the attribute's categories. items: $ref: '#/components/schemas/AttributeCategory' bins: type: array description: Contains the attribute's bins. Only continuous attributes can have bins. items: $ref: '#/components/schemas/AttributeBin' is\_unique: type: boolean description: Flag to set if this attribute should always be unique. default: false is\_positive\_predicted\_attribute: type: boolean description: Flag for binary classification models to specify positive predicted. attribute. default: false attribute\_link: type: string description: For predicted value or ground truth staged attributes this should be populated with a corresponding predicted value or ground truth attribute name. gt\_class\_link: type: string description: For predicted value, optional mapping to corresponding ground truth class values. implicit: type: boolean description: True if this attribute was created implicitly by the API. default: false type: object AttributeBin: description: A list of the attribute's bins. An attribute will only have bins if it is not categorical. The bin start is exclusive and the end is inclusive, (continuous\_start, continuous\_end]. Use Null to represent an open end of a bin. required: - continuous\_start - continuous\_end properties: continuous\_start: type: number description: The exclusive start value for the bucket. continuous\_end: type: number description: The inclusive end value for the bucket. AttributeCategory: description: A list of the attribute's categories. An attribute will only have categories if it is marked as categorical. required: - value properties: label: type: string description: A label for the category. value: type: string description: The category value. ExplainabilityResponse: description: Describes the explainability configuration of a model. The fields marked as 'expandable' will only be returned when we see the query param 'expand=explainability'. required: - enabled properties: model\_server\_cpu: type: string description: Expandable. The CPU units upper bound to apply to the explainability server. If not set, the container can use all of the CPU available on the node. Maximum precision is 1m. model\_server\_memory: type: string description: Expandable. The memory setting for the explainability server. If not set, will default to '1Gi'. explanation\_nsamples: type: integer description: Expandable. Number of samples to use when generating the explanation. For SHAP, this corresponds to the 'nsamples' parameter, which defaults to len(features) + 2048. For LIME, this corresponds to 'num\_samples', which defaults to 5000. explanation\_algo: type: string description: The algorithm to use to generate explanations. If explainability is enabled, this value will always be returned. We currently support 'lime' and 'shap' and default to 'lime'. enabled: type: boolean description: Flag that indicates whether explainability is enabled for the model, defaults to false. type: object ReferenceDataRequest: description: Reference set data to upload. type: object required: - reference\_data.parquet properties: reference\_data.parquet: description: Parquet file containing reference set data. type: string format: binary image\_data: description: For input type = Image models, this can be a single image file or a zip of multiple image files. reference\_data.parquet is also required when this field is specified. The values of the image attribute in reference\_data.parquet must match this file's filename for a single inference. When sending multiple inferences, the image attributes must match the paths of the corresponding images in the zipped image\_data. The number of images must match the number of rows in reference\_data.parquet. format: binary type: string FileInferenceData: description: File containing inferences to bulk upload and optional batch\_id OR file containing ground truth data. Either inferences.parquet or ground\_truths.parquet must be included in the request. type: object properties: inference\_data: description: Parquet or JSON file containing inferences. If JSON, follow the same format as the /inferences POST endpoint. type: string format: binary ground\_truth\_data: type: string format: binary description: Parquet file containing ground truth, must contain the partner\_inference\_id field and ground\_truth\_timestamp field. batch\_id: description: Optional batch\_id to append to inferences in the provided file type: string image\_data: description: For input type = Image models, this can be a single image file or a zip of multiple image files. inference\_data is also required when this field is specified. The values of the image attribute in inference\_data must match this file's filename for a single inference. When sending multiple inferences, the image attributes must match the paths of the corresponding images in the zipped image\_data. The number of images must match the number of inferences in inference\_data. format: binary type: string SageMakerInferenceData: description: File containing SageMaker Data Capture JSONL to bulk upload. type: object properties: inference\_data: description: | A SageMaker Data Capture JSONL file containing inferences. The filename must end with \".jsonl\". Its data fields can either be encoded in either a CSV or a JSON format. If a user opts for a JSON encoding, the model inputs must be of format `{"instances": [{"features": [feature0, feature1, ...]}, {"features": [...]}]}` and the model outputs must be of format `{"predictions":[[prediction0, prediction1, ...], [prediction0, prediction1...]]}` for each JSON object in the JSON line file. type: string format: binary required: true ParquetDataResponse: description: Summary of failures type: object required: - counts - failures properties: counts: $ref: '#/components/schemas/StatusCounts' failures: type: array description: An array of result objects for each inference. The order matches the original request order items: $ref: '#/components/schemas/ReferenceDataFailures' ReferenceDataFailures: description: Failure reason for a single reference record required: - message - status properties: message: type: string description: an error message example: missing field status: type: number description: HTTP status code for the result example: 400 SageMakerDataResponse: description: Summary of failures type: object required: - counts - failures properties: counts: $ref: '#/components/schemas/StatusCounts' failures: type: array description: An array of result objects for each inference. The order matches the original request order items: $ref: '#/components/schemas/SageMakerDataFailures' SageMakerDataFailures: description: Failure reason for a single reference record required: - message - status - event\_id - inference\_index\_in\_event properties: message: type: string description: an error message example: missing field status: type: number description: HTTP status code for the result example: 400 event\_id: type: string description: The SageMaker event\_id corresponding to the failed to ingest inference. example: unique-event-id inference\_index\_in\_event: type: integer description: The index of the inference within the SageMaker event, in case this event had multiple inferences under the same event\_id. example: 2 ModelRequest: required: - input\_type - output\_type - partner\_model\_id example: name: v3\_api\_example partner\_model\_id: id\_123 input\_type: TABULAR output\_type: MULTILABEL attributes: - name: model\_attribute\_0 value\_type: BOOLEAN stage: PIPELINE\_INPUT position: 0 - name: model\_predicted\_attr value\_type: BOOLEAN stage: PREDICTED\_VALUE properties: display\_name: type: string description: An optional display name for the model. maxLength: 255 partner\_model\_id: type: string description: Client provided unique id to associate with the model. This field must be unique across all active models cannot be changed once set! maxLength: 255 input\_type: type: string description: The type of the model's input data. We currently support "TABULAR", "NLP", and "IMAGE" (for CV models). example: TABULAR enum: - IMAGE - TABULAR - NLP output\_type: type: string description: The output type of the model. example: MULTILABEL enum: - MULTICLASS - MULTILABEL - REGRESSION is\_batch: type: boolean description: Boolean value to determine whether the model sends inferences in batch or streaming format. Defaults to False. example: False description: type: string description: Optional description of the model. maxLength: 255 attributes: type: array description: Attribute definitions for the model. Included in response only if the query param 'expand=attributes' is present. minItems: 1 items: $ref: '#/components/schemas/ModelAttributeResponse' tags: type: array description: Keywords to associate with the model. items: type: string classifier\_threshold: type: number description: 'Threshold value for classification models, default is 0.5.' text\_delimiter: type: string description: Only valid for models with `input\_type` equal to `NLP`. Represents the text delimiter to divide input strings. example: "," ModelUpdateRequest: properties: display\_name: type: string description: Display name of the model to update. maxLength: 255 description: type: string description: Description of model to update. maxLength: 255 attributes: type: array description: Attribute definitions to update on the model. Only ground\_truth attributes can be updated after inferences have been sent. Before inferences have been sent any attributes can be updated. The attributes provided in this class will replace the ones currently associated with the model. items: $ref: '#/components/schemas/ModelAttributeResponse' tags: type: array description: Tags to set on the model object. items: type: string classifier\_threshold: type: number description: 'Threshold value for classification models, default is 0.5. This can only be updated before any inferences have been sent' InferenceAttributeData: properties: attribute\_id: type: string description: The auto-generated unique UUID for the attribute associated with this datapoint. attribute\_name: type: string maxLength: 255 description: Name of the attribute associated with this datapoint. data\_value: anyOf: - type: number - type: string - type: boolean example: 1.0 description: value of the attribute for a specific inference. stage: $ref: '#/components/schemas/Stage' User: required: - id - email properties: id: type: string description: the unique id of the user first\_name: type: string description: The user's first name last\_name: type: string description: The user's last name email: type: string description: The user's email username: type: string description: The username the user can use to login roles: description: The user's roles in the current organization. type: array items: type: string alert\_notifications\_enabled: description: Whether or not the user will receive email notifications when alerts are triggered, defaults to 'false' type: boolean deprecated: true show\_intro\_sequence: description: Used by the Arthur dashboard to determine whether or not to show the user an intro sequence upon login type: boolean help\_mode\_enabled: description: Used by the Arthur dashboard to determine whether or not to show dashboard tooltips type: boolean created\_at: type: string format: date-time description: UTC timestamp of when the user was created UserResponse: description: Represents an application user, if the client is using a service token then only organization\_id and roles will be populated in the object required: - organization\_id - roles properties: id: type: string description: the unique id of the user organization\_id: type: string description: The ID of the users current context organization\_name: type: string description: The name of the users current context first\_name: type: string description: The user's first name last\_name: type: string description: The user's last name email: type: string description: The user's email username: type: string description: The username the user can use to login roles: description: The user's roles type: array items: type: string alert\_notifications\_enabled: description: Whether or not the user will receive email notifications when alerts are triggered, defaults to 'false' type: boolean deprecated: true show\_intro\_sequence: description: used by the Arthur dashboard to determine whether the user should be shown the intro sequence upon login type: boolean help\_mode\_enabled: description: Used by the Arthur dashboard to determine whether or not to show dashboard tooltips type: boolean plan: description: string representation of what plan the org of the returned user is associated with (ie. self-service or paidSaas) type: string created\_at: type: string format: date-time description: UTC timestamp of when the user was created contexts: type: array items: $ref: '#/components/schemas/UserContext' description: Contexts that the user has permissions in. UserContext: properties: name: type: string description: Name of the context. id: type: string description: UUID of the context. UpdateUserRequest: properties: old\_password: type: string description: The user's old password. Not required to update the password if the caller is a super admin. new\_password: type: string description: The user's new password first\_name: type: string description: The user's first name last\_name: type: string description: The user's last name email: type: string description: The user's email username: type: string description: The username the user will use to login roles: type: array items: type: string show\_intro\_sequence: type: boolean description: Used by the Arthur dashboard to determine whether the user should be shown the intro sequence upon login help\_mode\_enabled: description: Used by the Arthur dashboard to determine whether or not to show dashboard tooltips type: boolean UpdateCurrentUserRequest: properties: old\_password: type: string description: The user's old password. new\_password: type: string description: The user's new password first\_name: type: string description: The user's first name last\_name: type: string description: The user's last name email: type: string description: The user's email username: type: string description: The username the user will use to login show\_intro\_sequence: type: boolean description: Used by the Arthur dashboard to determine whether the user should be shown the intro sequence upon login help\_mode\_enabled: description: Used by the Arthur dashboard to determine whether or not to show dashboard tooltips type: boolean NewUserRequest: required: - organization\_id - username - email - password properties: first\_name: type: string description: The user's first name last\_name: type: string description: The user's last name email: type: string description: The user's email username: type: string description: The username the user will use to login password: type: string description: The user's password roles: type: array description: Available Standard Roles are [Administrator, Model Owner, User]. If not provided, user will default to "Model Owner". items: type: string alert\_notifications\_enabled: type: boolean description: Whether or not the user will receive email notifications when alerts are triggered, defaults to 'false' deprecated: true Inference: required: - id - timestamp - data properties: id: type: string description: The auto-generated unique UUID for the inference maxLength: 255 partner\_inference\_id: type: string description: User defined unique inference id maxLength: 255 timestamp: type: string format: date-time description: Inference UTC timestamp in ISO8601 format anomaly\_score: type: number description: This score shows anomalous an inference is and will fall between 0 and 1. A lower score suggests the inference is more anomalous/a larger outlier. data: type: array items: $ref: '#/components/schemas/InferenceAttributeData' explanation: $ref: '#/components/schemas/ExplanationInput' ExplanationInput: type: object additionalProperties: type: object additionalProperties: true InferenceData: description: The inference data to ingest. This should be a map of the attribute name to the attribute value. If ground truth data is included in the request, it should be added to the "ground\_truth\_data" field, not here. type: object additionalProperties: anyOf: - type: number - type: string - type: boolean GroundTruthData: description: Map of the ground truth attribute name to the attribute value type: object additionalProperties: anyOf: - type: number - type: string - type: boolean NewInferences: description: New inferences to save type: array items: $ref: '#/components/schemas/NewInference' NewInference: description: An inference to save required: - inference\_timestamp - partner\_inference\_id - inference\_data properties: inference\_timestamp: type: string description: UTC timestamp of when the inference was made in ISO8601 string format partner\_inference\_id: type: string description: A unique id to associate with the inference. This is needed if you wish to later update the inference with ground truth and provides a quick way to retrieve the inference later. batch\_id: type: string description: Optional batch that the inference should be associated with inference\_data: $ref: '#/components/schemas/InferenceData' ground\_truth\_timestamp: type: string description: Required if ground\_truth\_data is provided, this is the UTC timestamp to associate with the ground truth data ground\_truth\_data: $ref: '#/components/schemas/GroundTruthData' InferencesGroundTruth: description: List of inference ground truth data type: array items: $ref: '#/components/schemas/PartnerIdInferenceGroundTruth' PartnerIdInferenceGroundTruth: description: The inference ground truth required: - ground\_truth\_timestamp - partner\_inference\_id - ground\_truth\_data properties: ground\_truth\_timestamp: type: string description: The UTC timestamp to associate with the ground truth data partner\_inference\_id: type: string description: The pre-defined unique id associated with the inference. ground\_truth\_data: $ref: '#/components/schemas/GroundTruthData' PaginatedTagResponse: description: Paginated list of tags. properties: data: type: array items: $ref: '#/components/schemas/TagResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' TagResponse: properties: id: type: string description: UUID of the tag name: type: string description: Name of the tag TagUpdateRequest: properties: name: type: string description: New name to update tag with AlertRuleRequest: required: - bound - threshold - severity - metric\_id properties: name: type: string description: A name for the alert rule, a default will be generated if this is not supplied. bound: type: string enum: - upper - lower threshold: type: number description: threshold of alert rule metric\_id: type: string description: The UUID of the metric to use for this alert rule. metric\_parameters: type: object description: Parameter values to use when evaluating the metric. May only supply one value for each parameter. filters: type: array items: $ref: "#/components/schemas/QueryFilter" description: Additional filter(s) to apply when evaluating the alert rule. severity: type: string description: Priority of the alert rule which triggered this alert. enum: - warning - critical lookback\_period: type: number description: The lookback time or "window length" in minutes to use when calculating the alert rule metric. For example, a lookback period of 5 minutes for an alert rule on average prediction will calculate average prediction for the past 5 minutes in a rolling window format. This will default to 5 minutes subsequent\_alert\_wait\_time: type: number description: If metric continues to pass threshold this is the time in minutes to wait before triggering another alert. This defaults to 0. This does not need to be set for batch alerts. enabled: type: boolean description: Whether or not an alert rule is active. Defaults to true. created\_by: type: string description: UUID of the user that is creating this alert rule. Defaults to Null if not specified. example: name: low accuracy rate for high age metric\_id: e14e6aac-0c94-4a78-a104-871f70b8b476 parameters: classifier\_threshold: 0.3 filters: - property: Age comparator: gt value: 55 threshold: 200 bound: lower severity: warning lookback\_period: 360 subsequent\_alert\_wait\_time: 720 enabled: true AlertRuleResponse: required: - id - name - threshold - bound - severity - lookback\_period - subsequent\_alert\_wait\_time - enabled - metric\_id - metric\_name - metric\_query - metric\_type allOf: - $ref: '#/components/schemas/AlertRuleRequest' properties: id: type: string description: UUID of an alert rule metric\_query: description: This should be in the format described in our [Query Guide](/api-documentation/query\_guide.html). Note that you should not include timestamp or batch\_id filters as these should be dynamically added when fetching the metric. The query should use an aggregate function in the first select that maps to the result returned from the query. The query should return a single result. oneOf: - $ref: '#/components/schemas/QueryRequest' - $ref: '#/components/schemas/DataDriftRequest' metric\_type: type: string description: The metric type/category enum: - model\_output\_metric - model\_performance\_metric - model\_data\_drift\_metric - model\_data\_bound\_metric last\_updated\_by: type: string description: UUID of the user that last updated this alert rule. Null if not specified at time of creation or update. last\_updated\_at: type: string description: The time that this alert rule was created or last updated. alert\_counts: $ref: '#/components/schemas/AlertCounts' last\_metric\_value: type: number description: Metric value of the most recent triggered alert for this alert rule. Only included if include\_alert\_metadata query param is set to true. last\_triggered: type: string description: Timestamp of the most recent triggered alert for this alert rule. Only included if include\_alert\_metadata query param is set to true. example: id: 2905da23-fa72-4299-92d6-40007d3a2a03 metric\_id: e14e6aac-0c94-4a78-a104-871f70b8b476 metric\_name: Accuracy Rate metric\_query: select: - function: "accuracyRate" parameters: threshold: "{{ classifier\_threshold }}" name: low accuracy rate for high age parameters: classifier\_threshold: 0.3 filters: - property: Age comparator: gt value: 55 threshold: .5 bound: lower severity: warning lookback\_period: 360 subsequent\_alert\_wait\_time: 720 enabled: true last\_updated\_by: ae9c76c8-e0c3-493d-8b71-79ef1a640xxx last\_updated\_at: "2021-04-05T15:17:28.604533Z" alert\_counts: new: 10 acknowlewdged: 15 resolved: 3 last\_metric\_value: 0.5 last\_triggered: "2021-05-05T20:00:00.000000Z" AlertCounts: description: Alert counts for an alert rule by status. Only included if include\_alert\_metadata query param is set to true. properties: new: type: number acknowledged: type: number resolved: type: number AlertRulePatch: properties: name: type: string description: Optional new display name of the alert rule. Will replace the existing name if supplied. bound: type: string enum: - upper - lower threshold: type: number description: threshold of alert rule severity: type: string description: Priority of the alert rule which triggered this alert. enum: - warning - critical lookback\_period: type: number description: The lookback time in minutes to use when calculating the alert rule metric. For example, a Lookback Period of 3 minutes for an alert rule on average prediction will calculate average prediction for the past 3 minutes in a rolling window format. This will default to 1 minute subsequent\_alert\_wait\_time: type: number description: If metric continues to pass threshold this is the time in seconds to wait before triggering another alert. This defaults to 300 seconds (5 minutes). enabled: type: boolean description: Whether or not an alert rule is active. Defaults to true. last\_updated\_by: type: string description: UUID of the user that is updating this alert rule. Defaults to Null if not specified. PaginatedAlertRuleResponse: description: Paginated list of alert rules. properties: data: type: array items: $ref: '#/components/schemas/AlertRuleResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' AlertRequest: properties: status: type: string required: true description: Status to update alert with enum: - resolved - acknowledged AlertResponse: properties: id: type: string description: UUID of the alert timestamp: type: string format: date-time description: UTC timestamp in ISO8601 format when the alert was triggered window\_start: type: string description: UTC timestamp in ISO8601 of the metric's rolling window start time window\_end: type: string description: UTC timestamp in ISO8601 of the metric's rolling window end time metric\_value: type: number description: The metric value calculated between the window\_start and window\_end times message: type: string description: Message associated with the alert. model\_id: type: string description: UUID of the model the alert is on batch\_id: type: string description: Id of the batch which the alert was triggered for. Only valid for batch alert rules. status: type: string enum: - new - resolved description: Whether the alert has been resolved or not. organization\_id: type: string format: uuid description: The UUID of the organization corresponding to this alert. alert\_rule: $ref: '#/components/schemas/AlertRuleResponse' PaginatedAlertResponse: description: Paginated list of alert responses. properties: data: type: array items: $ref: '#/components/schemas/AlertResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' PaginatedAlertNotificationConfigurationsResponse: description: Paginated list of alert notification configurations properties: data: type: array items: $ref: '#/components/schemas/AlertNotificationConfiguration' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' AlertNotificationConfiguration: description: Tells us where and how to deliver an alert notification required: - id - model\_id - destination - type - enabled properties: id: type: string description: The unique UUID of this notification configuration example: "418c6939-8765-40fa-b04e-11ba57b7f21c" model\_id: type: string description: The UUID of the model that this alert notification config belongs to type: type: string enum: - email destination: type: string description: For a notification type of "email", this is the email address the notification will be delivered to. user\_id: type: string description: UUID of the user this notification config is associated with, if any. This field is required for email notifications. enabled: type: boolean description: Whether or not this notification config is enabled NewAlertNotificationConfiguration: description: a new alert notification configuration to create required: - model\_id - type example: model\_id: "c84296c5-b491-48a2-9a32-ae61a3a2f453" type: "email" user\_id: "8ebe06b1-0537-46a2-9379-eb1418d5ff85" properties: model\_id: type: string description: The UUID of the model that this alert notification config belongs to type: type: string enum: - email destination: type: string description: For a notification type of "email", this field does not need to be provided and will be automatically inferred from the user id. user\_id: type: string description: UUID of the user this notification config is associated with, if any. This field is required for email notifications. enabled: type: boolean description: Whether or not this notification config is enabled. Defaults to "true" default: True AlertNotificationConfigurationUpdate: description: The fields to update in the AlertNotificationConfiguration object properties: enabled: type: boolean description: Whether or not this notification config is enabled WhatIfAttributeRequest: description: "Attribute object for inference to be sent to what-if" properties: attribute\_name: type: string example: "feature\_a" attribute\_value: anyOf: - type: number - type: string - type: boolean example: 1.0 WhatIfRequest: description: "Inference model pipeline input to get explanation for" properties: model\_pipeline\_input: type: array items: $ref: '#/components/schemas/WhatIfAttributeRequest' ExplanationValuesOnDemand: properties: attribute\_name: type: string example: "feature\_a" explanation\_value: type: number example: 0.12 tokens: type: array description: Only valid for NLP models, represents the list of tokens locations and explanation values items: $ref: '#/components/schemas/TokenObject' ExplanationValuesWhatIf: properties: attribute\_name: type: string example: "feature\_a" explanation\_value: type: number example: 0.12 TokenObject: properties: token: type: string description: Token string which is generated from separating the input text by the model's given delimiter. example: dog position: type: number description: Integer representing the location of the token in the input text. 0 refers to the the first token in the input text. example: 0 explanation\_value: type: number description: Float explanation value for the specific token. example: 0.48 ExplanationsOnDemand: properties: algorithm: type: string example: "shap" predicted\_attribute\_name: type: string example: "class\_a" importance\_scores: type: array items: $ref: '#/components/schemas/ExplanationValuesOnDemand' ExplanationsWhatIf: properties: algorithm: type: string example: "shap" predicted\_attribute\_name: type: string example: "class\_a" importance\_scores: type: array items: $ref: '#/components/schemas/ExplanationValuesWhatIf' ExpectedValues: properties: predicted\_attribute\_name: type: string example: "feature\_a" expected\_value: type: number example: 0.12 ExplainabilityResultOnDemand: properties: explanation: type: array items: $ref: '#/components/schemas/ExplanationsOnDemand' expected\_value: type: array items: $ref: '#/components/schemas/ExpectedValues' ExplainabilityResultWhatIf: properties: predicted\_values: type: array items: $ref: '#/components/schemas/WhatIfAttributeRequest' explanation: type: array items: $ref: '#/components/schemas/ExplanationsWhatIf' expected\_value: type: array items: $ref: '#/components/schemas/ExpectedValues' InferencesResponse: description: Statuses for each inference required: - counts - results properties: counts: $ref: '#/components/schemas/StatusCounts' results: type: array description: An array of result objects for each inference. The order matches the original request order items: $ref: '#/components/schemas/InferenceResult' InferenceResult: description: Result for a single inference required: - message - status properties: message: type: string description: either "success" or an error message example: success status: type: number description: HTTP status code for the result example: 200 StatusCounts: description: Counts of the results by status required: - success - failure - total properties: success: type: number description: The number of successful inferences in the request failure: type: number description: The number of failed inferences in the request total: type: number description: The total number of inferences in the request DatasetStatusEnum: type: string enum: - started - uploaded - processing - completed - failed description: The status of the dataset. DatasetsResponse: type: array items: $ref: '#/components/schemas/DatasetResponse' DatasetResponse: type: object properties: model\_id: type: string description: The unique UUID for the model. type: type: string enum: - batch - reference description: The type of dataset. batch\_id: type: string description: The id of the batch. Only returned for "batch" type datasets. records: type: integer description: The number of records in the dataset partner\_record\_count: type: integer description: The total number of records sent by the customer. This is an optional field that is populated by the "total\_record\_count" in the dataset POST request. status: $ref: '#/components/schemas/DatasetStatusEnum' created\_at: type: string description: Timestamp the dataset was created in the Arthur platform. updated\_at: type: string description: Timestamp the dataset was last updated in the Arthur platform. SuccessResponse: type: object properties: message: type: string example: success ClosedRequest: type: object required: - status properties: status: type: string example: uploaded description: Setting the status to "uploaded" will close the batch and start the dataset post-processing. total\_record\_count: description: A total count of all the records in this dataset across all calls to ingestion service. This is intended to come from the customer so we can verify no data was lost in transmission. type: integer ReferenceDatasetResponse: type: object properties: model\_id: type: string description: The unique UUID for the model. records: type: integer description: The number of records in the dataset partner\_record\_count: type: integer description: The total number of records sent by the customer. This is an optional field that is populated by the "total\_record\_count" in the dataset POST request. status: $ref: '#/components/schemas/DatasetStatusEnum' created\_at: type: string description: Timestamp the dataset was created in the Arthur platform. updated\_at: type: string description: Timestamp the dataset was last updated in the Arthur platform. BatchResponse: type: object properties: model\_id: type: string description: The unique UUID for the model. batch\_id: type: string description: The id of the batch. Only returned for "batch" type datasets. records: type: integer description: The number of records in the dataset partner\_record\_count: type: integer description: The total number of records sent by the customer. This is an optional field that is populated by the "total\_record\_count" in the dataset POST request. status: $ref: '#/components/schemas/DatasetStatusEnum' created\_at: type: string description: Timestamp the dataset was created in the Arthur platform. updated\_at: type: string description: Timestamp the dataset was last updated in the Arthur platform. BiasMitigationCurveResponse: type: object properties: id: type: string description: UUID of the bias mitigation curve. example: "418c6939-8765-40fa-b04e-11ba57b7f21c" attribute\_id: type: string description: UUID of the attribute which the curve is associated with. example: "418c6939-8765-40fa-b04e-11ba57b7f21c" attribute\_name: type: string description: Name of the attribute which the curve is associated with. example: "Gender" categorical\_value: type: string description: Categorical attribute value which the curve is associated with. example: "Male" continuous\_start: type: string description: Start of the range in which the curve is associated with for continuous attributes. Will only exist for continuous attributes and will always have a corresponding continuous\_end. A none value denotes an open bound. example: "18" continuous\_end: type: string description: End of the range in which the curve is associated with for continuous attributes. Will only exist for continuous attributes and will always have a corresponding continuous\_end. A none value denotes an open bound. example: "65" constraint: type: string description: Constraint value which the curve is associated with. example: "Demographic Parity" x\_label: type: string description: X axis label of the curve, derived from constraint type. example: "Selection Rate" y\_label: type: string description: Y axis label of the curve, derived from constraint type. example: "Accuracy" optimization\_index: type: integer description: Index of the curve point which is most optimized according to the constraint. data\_points: type: array items: $ref: '#/components/schemas/BiasMitigationDataPoints' description: Timestamp the file was last updated in the Arthur platform. BiasMitigationDataPoints: type: object properties: x: type: number description: x-coordinate of the point on the curve. example: 0.78 y: type: number description: y-coordinate of the point on the curve. example: 0.28 threshold: type: number description: Threshold associated with specific point on the curve. example: 0.8 PaginatedBiasMitigationCurves: properties: data: type: array description: List of bias mitigation curves. items: $ref: '#/components/schemas/BiasMitigationCurveResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' AnomalyDetectionEnrichmentConfiguration: required: - enabled properties: enabled: type: boolean description: Whether or not the enrichment is enabled default: true BiasMitigationEnrichmentConfiguration: required: - enabled properties: enabled: type: boolean description: Whether or not the enrichment is enabled default: false HotspotsEnrichmentConfiguration: required: - enabled properties: enabled: type: boolean description: Whether or not the enrichment is enabled default: false ExplainabilityEnrichmentConfiguration: description: JSON-formatted configuration options for the Explainability Enrichment. See the ExplainabilityEnrichmentConfiguration for schema. type: object required: - enabled - python\_version - sdk\_version - streaming\_explainability\_enabled - user\_predict\_function\_import\_path properties: enabled: type: boolean description: Whether or not the enrichment is enabled default: false config: type: object properties: python\_version: description: Python version number user project users type: string sdk\_version: description: SDK version number user project uses type: string streaming\_explainability\_enabled: description: Set to true if explainability should be calculated for all inferences in a streaming manner and set to false if explainability should only be calculated when requested. type: boolean user\_predict\_function\_import\_path: description: Import path of the user model predict function in the project directory type: string shap\_expected\_values: description: If using SHAP, these are the expected values generated when the explainer is created type: array items: type: number model\_server\_cpu: description: Number of cpus to assign to explanation server. type: string default: '2' model\_server\_memory: description: Amount of memory to assign explanation server in the format xMi or xGi. type: string default: '1500Mi' model\_server\_max\_replicas: description: Max number of model server instances. type: integer default: 30 explanation\_nsamples: description: Explainability algorithms create sample data points when explaining inferences. The number of samples created per explanation can be configured here. There is a trade off between accuracy and computing power and time for this configuration. type: integer default: 2000 explanation\_algo: description: Explainability algorithm to use in the model server. Current options are "lime" or "shap", default is "lime" type: string enum: - lime - shap default: lime inference\_consumer\_cpu: description: Number of cpus to assign to the inference reader type: string default: '500m' inference\_consumer\_memory: description: Amount of memory to assign to the inference reader in the format xMi or xGi. type: string default: '512Mi' inference\_consumer\_score\_percent: description: Sampling rate for inferences to explain type: number default: 1.0 inference\_consumer\_thread\_pool\_size: description: Number of threads in the inference consumer pool type: integer default: 5 + + + ExplainabilityEnrichmentArtifacts: description: Artifacts for enrichments properties: user\_project.zip: description: Zipped folder of model predict function and code dependencies type: string format: binary user\_requirements\_file.txt: description: Text file containing python dependencies the project folder requires type: string format: binary explainer.pkl: description: Serialized LIME or SHAP explainer object type: string format: binary + + + EnrichmentsConfiguration: description: A JSON-formatted enrichments configuration. See the EnrichmentsConfiguration object for schema type: object properties: anomaly\_detection: $ref: '#/components/schemas/AnomalyDetectionEnrichmentConfiguration' bias\_mitigation: $ref: '#/components/schemas/BiasMitigationEnrichmentConfiguration' hotspots: $ref: '#/components/schemas/HotspotsEnrichmentConfiguration' explainability: $ref: '#/components/schemas/ExplainabilityEnrichmentConfiguration' + + + # TODO: to be used in status update EnrichmentStatus: properties: pipeline\_status: type: string enum: - disabled - updating - ready description: status of the enrichment pipeline, the status will be 'updating' while enrichments are being reconfigured, and 'ready' or 'disabled' when the updates are complete. EnrichmentsStatus: type: object description: The response object containing configuration and status of all enrichments. properties: anomaly\_detection: $ref: '#/components/schemas/EnrichmentStatus' bias\_mitigation: $ref: '#/components/schemas/EnrichmentStatus' explainability: $ref: '#/components/schemas/EnrichmentStatus' + + + AnomalyDetectionEnrichmentResponse: type: object description: The response object containing configuration and status of an on-by-default enrichment. allOf: # - $ref: '#/components/schemas/EnrichmentStatus' - $ref: '#/components/schemas/AnomalyDetectionEnrichmentConfiguration' BiasMitigationEnrichmentResponse: type: object description: The response object containing configuration and status of an on-by-default enrichment. allOf: # - $ref: '#/components/schemas/EnrichmentStatus' - $ref: '#/components/schemas/BiasMitigationEnrichmentConfiguration' HotspotsEnrichmentResponse: type: object description: The response object containing configuration and status of an on-by-default enrichment. allOf: # - $ref: '#/components/schemas/EnrichmentStatus' - $ref: '#/components/schemas/HotspotsEnrichmentConfiguration' FindHotspotsNode: type: object properties: rules: type: object description: rules for the split on this node gt\_to\_info: type: object description: info around ground truths at this node precision: type: object description: precision for this node recall: type: object description: recall for this node f1: type: object description: f1 for this node accuracy: type: object description: accuracy for this node impurity: type: object description: impurity for this node n\_samples: type: object description: n\_samples used for this node feature: type: object description: name of feature this node was cut on cutoff: type: object description: the cutoff for the node FindHotspotsResponse: type: object properties: data: type: array items: $ref: '#/components/schemas/FindHotspotsNode' description: Contains all hotspots based on input ExplainabilityEnrichmentResponse: type: object description: The response object containing configuration and status of the explainability enrichment. allOf: # - $ref: '#/components/schemas/EnrichmentStatus' - $ref: '#/components/schemas/ExplainabilityEnrichmentConfiguration' EnrichmentsResponse: type: object description: The response object containing configuration and status of all enrichments. properties: anomaly\_detection: $ref: '#/components/schemas/AnomalyDetectionEnrichmentResponse' bias\_mitigation: $ref: '#/components/schemas/BiasMitigationEnrichmentResponse' hotspots: $ref: '#/components/schemas/HotspotsEnrichmentResponse' explainability: $ref: '#/components/schemas/ExplainabilityEnrichmentResponse' + + + ExplainabilityEnrichmentRequest: type: object description: Configures explainability. A multipart/form-data body with at least a `configuration` JSON body. If explainability is being enabled for the first time, artifacts must be supplied. required: - config properties: config: $ref: '#/components/schemas/ExplainabilityEnrichmentConfiguration' allOf: - $ref: '#/components/schemas/ExplainabilityEnrichmentArtifacts' EnrichmentsRequest: type: object description: Configures multiple enrichments. A multipart/form-data body with at least a `configuration` JSON body. If explainability is being enabled for the first time, artifacts must be supplied. required: - config properties: config: $ref: '#/components/schemas/EnrichmentsConfiguration' allOf: - $ref: '#/components/schemas/ExplainabilityEnrichmentArtifacts' PaginatedModelMetricsResponse: description: Paginated list of metrics. properties: metrics: type: array items: $ref: '#/components/schemas/MetricResponse' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' NewMetricRequest: description: Contains the new metric object to create required: - name - endpoint - query example: name: class rate endpoint: "/api/v3/models/00000000-0000-0000-0000-000000000000/inferences/query" query: select: - function: rate # TODO: add parameters here parameters: property: class\_a comparator: gte value: 0.5 type: "model\_performance\_metric" created\_by: 10000000-0000-0000-0000-000000000000 properties: name: type: string description: The name for your custom metric, this should not match any other metric name for the model and cannot match any Arthur default metric names. endpoint: type: string description: The relative endpoint to hit when executing this metric example: "/api/v3/models/00000000-0000-0000-0000-000000000000/inferences/query" query: description: This should be in the format described in our [Query Guide](/api-documentation/query\_guide.html). Note that you should not include timestamp or batch\_id filters as these should be dynamically added when executing the metric. oneOf: - $ref: '#/components/schemas/QueryRequest' - $ref: '#/components/schemas/DataDriftRequest' type: description: Type associated with the metric to create. If this field is not supplied the metric type will automatically be filled in. type: string enum: - model\_output\_metric - model\_performance\_metric - model\_data\_drift\_metric - model\_data\_bound\_metric parameters: type: array items: $ref: "#/components/schemas/MetricParameterRequest" created\_by: type: string description: UUID of the user that created this metric. Will be set to Null if not specified. MetricResponse: allOf: - $ref: '#/components/schemas/MetricRequest' - properties: id: type: string format: uuid valid\_rollups: description: The allowed "rollup" parameters for this metric type: array items: type: string example: ["MINUTE", "HOUR", "DAY", "MONTH", "REFERENCE"] parameters: type: array items: $ref: "#/components/schemas/MetricParameterResponse" + + + MetricRequest: description: A Metric containing a template query and parameter definitions type: object required: - name - endpoint - query properties: name: type: string description: The name for your custom metric, this should not match any other metric name for the model and cannot match any Arthur default metric names. example: Accuracy Rate endpoint: type: string description: The relative endpoint to hit when executing this metric example: "/api/v3/models/4d722041-7274-6875-7220-53616d75656c/inferences/query" query: $ref: '#/components/schemas/MetricQuery' type: description: Type associated with the metric to create. If this field is not supplied the metric type will automatically be filled in. type: string enum: - model\_output\_metric - model\_performance\_metric - model\_data\_drift\_metric - model\_data\_bound\_metric parameters: type: array items: $ref: "#/components/schemas/MetricParameterRequest" created\_by: type: string format: uuid description: UUID of the user that created this metric. Will be set to Null if not specified. + + + MetricQuery: type: object description: This should be in the format described in our [Query Guide](/api-documentation/query\_guide.html). Your query must have exactly one select and may not use the `group\_by` or `subquery` fields. Don't include any batch or timestamp filters as these will be added dynamically. For details see example: select: - function: accuracyRate parameters: threshold: "{{ classifier\_threshold }}" + + + MetricParameterRequest: description: A Parameter specification for a Metric type: object required: [ 'name', 'parameter\_type', 'value\_limits', 'default' ] properties: name: type: string example: classifier\_threshold parameter\_type: $ref: '#/components/schemas/ParameterType' value\_limits: type: object description: Acceptable values for the parameter. Exactly one of `categorical` or `range` must be specified. oneOf: - type: object properties: range: allOf: - $ref: "#/components/schemas/RangeValueLimits" - type: object properties: categorical: allOf: - $ref: "#/components/schemas/CategoricalValueLimits" + + + default: description: Default value(s) for the parameter. If not provided, it will be inferred if possible. example: 0.5 + + + MetricParameterResponse: allOf: - $ref: "#/components/schemas/MetricParameterRequest" properties: id: type: string format: uuid + + + ParameterType: description: The type of a supplied parameter type: string enum: [ "ATTRIBUTE", "INTEGER", "FLOAT", "STRING", "TIMESTAMP" ] example: FLOAT + + + RangeValueLimits: description: Possible values between a minimum and maximum value type: object required: [ "min", "max" ] properties: min: description: The minimum value allowed. Not required if it can be inferred. type: number example: 0.0 max: description: The maximum value allowed. Not required if it can be inferred. type: number example: 1.0 + + + CategoricalValueLimits: description: Possible values within fixed set type: object required: [ "categories" ] properties: categories: description: The list of allowed values. Not required if it can be inferred. type: array items: { } + + + MetricParameterValues: type: object additionalProperties: oneOf: - type: array items: oneOf: - type: number - type: string - type: number - type: string example: classifier\_threshold: [ 0.5, 0.3 ] + + + Rollup: description: What period/dataset to aggregate over. type: string enum: [ "MINUTE", "HOUR", "DAY", "MONTH", "YEAR", "BATCH", "REFERENCE" ] example: DAY + + + MetricGroupBy: description: Model attribute to group by. If provided, the results will be broken down by each value or bin in the attribute required: false type: array items: type: string example: - "Education" + + + GroupLegend: description: Specification of group for a metric result. type: object properties: name: type: string description: the name of the group, if group is categorical bin: type: object description: the bin start and end, if group is continuous properties: continuous\_start: type: number description: the start of the bin continuous\_end: type: number description: the end of the bin + + + MetricEvaluationRequest: description: The arguments to use when evaluating a metric type: object properties: rollup: $ref: '#/components/schemas/Rollup' group\_by: $ref: '#/components/schemas/MetricGroupBy' parameters: $ref: '#/components/schemas/MetricParameterValues' filters: type: array items: $ref: '#/components/schemas/QueryFilter' + + + MetricEvaluationResponse: description: The result of a metric evaluation type: object required: - name - results properties: name: type: string description: The name of the metric example: Accuracy Rate filters: description: The dataset filters used during metric evaluation type: array items: $ref: "#/components/schemas/QueryFilter" results: description: The results of metric evaluation type: array items: $ref: "#/components/schemas/MetricResult" + + + MetricResult: description: The result of a metric evaluation on a set of parameters, filters, and group type: object required: - name - values properties: name: type: string description: The function name or alias of the metric example: Accuracy Rate values: description: the value of the metric, aggregating by the rollup type: array items: type: object required: - rollup properties: rollup: type: string description: The time aggregation associated with this metric value example: "2022-08-03T00:00:00+00:00" additionalProperties: oneOf: - type: string - type: number format: float example: - rollup: "2022-08-03T00:00:00+00:00" accuracy\_rate: 0.82 - rollup: "2022-08-04T00:00:00+00:00" accuracy\_rate: 0.76 - rollup: "2022-08-05T00:00:00+00:00" accuracy\_rate: 0.80 parameters: type: object additionalProperties: oneOf: - type: number - type: string example: classifier\_threshold: 0.5 description: the parameters used when evaluating the metric group: description: the grouping applied type: object additionalProperties: $ref: "#/components/schemas/GroupLegend" example: { "Education": { "name": "HS" } } + + + ModelHealthResponse: required: - results properties: results: type: array items: $ref: '#/components/schemas/ModelHealthScore' ModelHealthScore: required: - model\_id - health\_score - timestamp properties: model\_id: type: string description: id of the model example: 8519dce3-d1fd-4791-9f17-c15f43e43dcf health\_score: type: number description: the health score of the model between 0-100 example: 78.9823 timestamp: type: string description: the time the health score was calculated in UTC example: 2021-05-21T00:00:00.000Z PaginatedAlertSummaryConfigurationsResponse: description: Paginated list of alert summary configurations properties: data: type: array items: $ref: '#/components/schemas/AlertSummaryConfiguration' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' AlertSummaryConfiguration: description: Specify the contents of an alert summary as well as when and where to send it required: - id - name - owner\_user\_id - frequency - send\_time\_of\_day - models - subscribers - enabled properties: id: type: string description: The unique UUID of this alert summary configuration example: "418c6939-8765-40fa-b04e-11ba57b7f21c" name: type: string description: The user defined name of this alert summary configuration. Must be unique within the org owner\_user\_id: type: string description: The unique id of the user that created this alert summary configuration frequency: type: string enum: - daily - weekly description: The cadence on which to send out the alert summary to subscribers send\_day\_of\_week: type: string enum: - Monday - Tuesday - Wednesday - Thursday - Friday - Saturday - Sunday description: The day of the week to send the alert summary to subscribers. Only required if frequency is Weekly. send\_time\_of\_day: type: string description: The time on a given day to send the alert summary to subscribers in the format "00:00". example: 09:00 models: description: The models that should be included in the alert summary type: array items: type: string description: UUID of the model to include subscribers: description: collection of notification configurations that define where to send this alert summary type: array items: $ref: '#/components/schemas/AlertSummaryNotificationConfiguration' enabled: type: boolean description: Whether or not this Alert Summary configuration is enabled. default: True NewAlertSummaryConfiguration: description: a new alert summary configuration to create required: - name - frequency - send\_time\_of\_day properties: name: type: string description: The user defined name of this alert summary configuration. Must be unique within the org frequency: type: string enum: - daily - weekly description: The cadence on which to send out the alert summary to subscribers send\_day\_of\_week: type: string enum: - Monday - Tuesday - Wednesday - Thursday - Friday - Saturday - Sunday description: The day of the week to send the alert summary to subscribers. Only required if frequency is Weekly. send\_time\_of\_day: type: string description: The time on a given day to send the alert summary to subscribers in the format "00:00". example: 09:00 models: description: The models that should be included in the alert summary type: array items: type: string description: UUID of the model to include subscribers: description: collection of notification configurations that define where to send this alert summary type: array items: $ref: '#/components/schemas/NewAlertSummaryNotificationConfiguration' AlertSummaryConfigurationUpdate: description: the updated AlertSummaryConfiguration object properties: name: type: string description: The user defined name of this alert summary configuration. Must be unique within the org frequency: type: string enum: - daily - weekly description: The cadence on which to send out the alert summary to subscribers send\_day\_of\_week: type: string enum: - Monday - Tuesday - Wednesday - Thursday - Friday - Saturday - Sunday description: The day of the week to send the alert summary to subscribers. Only required if frequency is Weekly. send\_time\_of\_day: type: string description: The time on a given day to send the alert summary to subscribers in the format "00:00". example: 09:00 models: description: The models that should be included in the alert summary type: array items: type: string description: UUID of the model to include enabled: type: boolean description: Whether or not this Alert Summary configuration is enabled. default: true PaginatedAlertSummaryNotificationConfigurationsResponse: description: Paginated list of alert summary configurations properties: data: type: array items: $ref: '#/components/schemas/AlertSummaryNotificationConfiguration' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' AlertSummaryNotificationConfiguration: description: Tells us where and how to deliver an alert summary required: - id - type - destination properties: id: type: string description: the unique UUID of this AlertSummaryNotificationConfiguration type: type: string enum: - email destination: type: string description: For a notification type of "email", this is the email address the alert summary will be delivered to user\_id: type: string description: UUID of the user this alert summary notification configuration is associated with, if any. This field is required for notifications of type "email". enabled: type: boolean description: Whether or not this Alert Summary Notification configuration is enabled. default: true AlertSummaryNotificationConfigurationUpdate: description: the updated AlertSummaryNotificationConfiguration object properties: enabled: type: boolean description: Whether or not this Alert Summary Notification configuration is enabled. NewAlertSummaryNotificationConfiguration: description: Tells us where and how to deliver an alert summary required: - type properties: type: type: string enum: - email destination: type: string description: For a notification type of "email", this will be auto-populated with the email address associated with the specified user\_id. If provided, it must match the email address associated with the specified user\_id. user\_id: type: string description: UUID of the user this alert summary notification configuration is associated with, if any. This field is required for notifications of type "email". PaginatedAlertSummaryReportsResponse: description: Paginated list of alert summary reports properties: data: type: array items: $ref: '#/components/schemas/AlertSummaryReport' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' AlertSummaryReport: description: Contents of an alert summary report to be sent required: - report\_id - configuration\_id - time\_frame - data properties: report\_id: type: string description: unique UUID of this alert summary report configuration\_id: type: string description: UUID of the alert summary report configuration associated with this report time\_frame: type: string description: the start to end time frame in UTC for this report data: description: alert summary data line items to include in the report type: array items: $ref: '#/components/schemas/AlertSummaryReportLineItem' AlertSummaryReportLineItem: description: data for a specific alert line item to be included in an alert summary report required: - model\_id - alert\_check\_name - alert\_check\_threshold - alert\_count properties: model\_id: type: string description: UUID of the model that this alert data belongs to alert\_check\_name: type: string description: the name of the alert rule to display in the report alert\_check\_threshold: type: string description: the threshold configured for the alert rule this alert data belongs to alert\_count: type: number description: the count of alerts that were triggered for the alert rule this alert data belongs to hyperlink: type: string description: a click-able url link that should be embedded into this line item for the alert summary report BulkAlertUpdateResponse: description: Information on the outcome of a bulk alert update properties: UpdatedAlerts: type: integer description: The number of alerts updates for the alert rule EmailNotificationBody: properties: model\_id: type: string format: uuid alert\_timestamp: type: string format: date-time alert\_description: type: string alert\_priority: type: string enum: - warning - critical required: - model\_id - alert\_timestamp - alert\_description - alert\_priority PaginatedInsights: description: Paginated list of insights. properties: data: type: array items: $ref: '#/components/schemas/Insight' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' Insight: properties: id: type: string description: UUID of the insight model\_id: type: string description: UUID of the model the insight is on batch\_id: type: string description: Id of the batch which the insights was generated for. Only valid for batch models. run\_id: type: string description: UUID of the corresponding workflow run in dataset-service that triggered the generation of this insight. metric\_type: type: string enum: - accuracyHotspot description: the metric this insight is calculate for. Only accuracy hotspots insights are supported for now. threshold\_value: type: number description: the threshold value the metric is checked against region: type: object description: bounds on model inputs associated with this insight metric\_value: type: number description: the value of this input region for the specified metric type timestamp: type: string format: date-time description: UTC timestamp in ISO8601 format when the insight was created window\_start: type: string format: date-time description: Only for streaming models. UTC timestamp in ISO8601, of the start time boundary of hotspot checking window\_end: type: string format: date-time description: Only for streaming models. UTC timestamp in ISO8601, of the end time boundary of hotspot checking status: type: string enum: - new - resolved description: Whether the alert has been resolved or not. example: id: be7f5901-c8db-4db9-a7a8-ec99eadf4e21 model\_id: 16c139ab-bb3e-4b0c-a645-887d2bd468fe batch\_id: "batch-122" run\_id: 55c86a4c-5d88-4ac0-8586-c9626f52741c metric\_type: "accuracyHotspot" threshold\_value: 0.4 region: { "AGE": { "lte": 23.5 }, "PAY\_AMT4": { "gt": 532.5 }, "PAY\_AMT5": { "lte": 6 } } metric\_value: 0.3 timestamp: "2021-07-12T01:08:05.842584Z" status: "new" InsightPatch: properties: status: type: string required: true description: Status to update alert with enum: - new - resolved - acknowledged InsightUpdateResponse: description: Information on the outcome of an insight(s) update properties: UpdatedCount: type: integer description: The number of insights updated PermissionRequest: properties: resource: type: string required: true description: The resource the request is trying to act upon action: type: string required: true description: The action the request is trying to take on the resource RoleDefinitionRequest: properties: role\_name: type: string required: true description: The name of the role you are creating permissions: description: A list of permissions to associate with the role. See Arthur Docs for available permissions type: array items: $ref: '#/components/schemas/PermissionRequest' inherited\_role\_names: description: A list of roles to inherit permissions from. These can be user defined roles or Arthur default roles. See Arthur docs for default roles type: array items: type: string CustomRBACRequest: properties: roles: description: A list of RoleDefinitionRequests type: array items: $ref: '#/components/schemas/RoleDefinitionRequest' RolesRequest: properties: roles: description: A list of roles type: array items: type: string organization\_id: description: The UUID of the organization type: string AuthenticationInfo: properties: organization\_ids: description: A list of organization IDs. type: array items: type: string issuer: description: The identifier of the IDP managing this user. type: string external\_user\_id: description: An identifier for an external-IdP token bearer. Populated if this user's token came from an IDP and the IDP configuration specified an oidc.CustomClaimNames that mapped UserID to a claim. type: string internal\_user\_id: description: An identifier for an Arthur-internal user. Populated for Arthur-authenticated users with user tokens. type: string service\_account\_id: description: An identifier for an Arthur service account. Populated for Arthur-authenticated service account tokens. type: string username: description: Either the Arthur username or the username specified by an external IDP. This will be set to arthur.ServiceAccountName for service account tokens. type: string first\_name: description: The first name of the Arthur authenticated user, or the first name claim if the external IDP is configured with one. type: string last\_name: description: The last name of the Arthur authenticated user, or the last name claim if the external IDP is configured with one. type: string email: description: The email of the Arthur authenticated user or the email of the external IDP user if the IDP is configured with that claim. For Arthur service accounts, this will be empty. type: string roles: description: The list of roles that this user has. For Arthur tokens, there will always be one role in this array; however, there can be more than one for external providers. type: array items: type: string SetCurrentOrganizationRequest: required: - organization\_id properties: organization\_id: type: string NewOrganizationRequest: required: - name properties: name: type: string roles: description: A list of RoleDefinitionRequest objects that define the custom RBAC for this organization type: array items: $ref: '#/components/schemas/RoleDefinitionRequest' UpdateOrganizationRequest: properties: name: type: string plan: type: string Organization: required: - id - name properties: id: type: string format: uuid description: Unique UUID for the organization example: '12345678-90ab-cdef-1234-567890abcdef' name: type: string bucket\_name: type: string bucket\_url: type: string plan: type: string description: The organization's license plan for platform usage example: enterprise created\_at: format: date-time description: The time in UTC that the org was created updated\_at: format: date-time description: The time in UTC that the org was last updated roles: description: A list of RoleDefinitionRequest objects that define the custom RBAC for this organization type: array items: $ref: '#/components/schemas/RoleDefinitionRequest' PaginatedOrganizations: required: - data - page - page\_size properties: data: type: array description: List of organizations. items: $ref: '#/components/schemas/Organization' page: $ref: '#/components/schemas/Page' page\_size: $ref: '#/components/schemas/PageSize' total\_pages: $ref: '#/components/schemas/TotalPages' total\_count: $ref: '#/components/schemas/TotalCount' OrganizationLimits: properties: organization\_id: type: string format: uuid description: Unique UUID for the organization example: '12345678-90ab-cdef-1234-567890abcdef' plan: type: string description: The organization's license plan for platform usage example: enterprise max\_users: type: integer format: int64 example: 10 description: maximum number of active users permitted in the organization max\_user\_invites: type: integer format: int64 example: 20 description: maximum number of user invitations permitted to be sent for the organization max\_service\_accounts: type: integer format: int64 example: 10 description: maximum number of service accounts permitted in the organization max\_shareable\_states: type: integer format: int64 example: 500 description: maximum number of shareable states that can be created in the organization max\_active\_models: type: integer format: int64 example: 3 description: maximum number of active models permitted in the organization max\_total\_models: type: integer format: int64 example: 10 description: maximum number of total models permitted in the organization (deleted models count toward this total) max\_model\_attributes: type: integer format: int64 example: 100 description: maximum number of attributes permitted on any given model in the organization max\_predicted\_model\_attributes: type: integer format: int64 example: 20 description: maximum number of predicted attributes permitted on any given model in the organization max\_categories\_per\_attribute: type: integer format: int64 example: 20 description: maximum number of categories any given model attribute can have in the organization max\_bias\_groups: type: integer format: int64 example: 100 description: maximum number of bias groups permitted on any given model in the organization max\_tags: type: integer format: int64 example: 10 description: maximum number of tags any given model can have in the organization max\_alert\_rules\_per\_model: type: integer format: int64 example: 500 description: maximum number of alert rules that can be set across all models in the organization max\_custom\_metrics: type: integer format: int64 example: 100 description: maximum number of custom metrics permitted on any given model in the organization inference\_count\_per\_request\_limit: type: integer format: int64 example: 100000 description: maximum number of inferences that can be sent in a single request in the organization inference\_count\_monthly\_model\_limit: type: integer format: int64 example: 500000 description: maximum number of inferences that can be sent to a single model over a rolling 30 day period in the organization inference\_count\_monthly\_total\_limit: type: integer format: int64 example: 500000 description: maximum number of inferences that can be sent across all models over a rolling 30 day period in the organization inference\_bytes\_per\_request\_limit: type: integer format: int64 example: 4294967296 description: maximum byte size of inferences that can be sent in a single request in the organization inference\_bytes\_monthly\_model\_limit: type: integer format: int64 example: 68719476736 description: maximum byte size of inferences that can be sent to a single model over a rolling 30 day period in the organization inference\_bytes\_monthly\_total\_limit: type: integer format: int64 example: 1099511627776 description: maximum byte size of inferences that can be sent across all models over a rolling 30 day period in the organization ground\_truth\_count\_per\_request\_limit: type: integer format: int64 example: 100000 description: maximum number of ground truth data points that can be sent in a single request in the organization ground\_truth\_count\_monthly\_model\_limit: type: integer format: int64 example: 500000 description: maximum number of ground truth data points that can be sent to a single model over a rolling 30 day period in the organization ground\_truth\_count\_monthly\_total\_limit: type: integer format: int64 example: 500000 description: maximum number of ground truth data points that can be sent across all models over a rolling 30 day period in the organization ground\_truth\_bytes\_per\_request\_limit: type: integer format: int64 example: 4294967296 description: maximum byte size of ground truth data that can be sent in a single request in the organization ground\_truth\_bytes\_monthly\_model\_limit: type: integer format: int64 example: 68719476736 description: maximum byte size of ground truth data that can be sent to a single model over a rolling 30 day period in the organization ground\_truth\_bytes\_monthly\_total\_limit: type: integer format: int64 example: 1099511627776 description: maximum byte size of ground truth data that can be sent across all models over a rolling 30 day period in the organization reference\_data\_count\_per\_request\_limit: type: integer format: int64 example: 100000 description: maximum number of reference data points that can be sent in a single request in the organization reference\_data\_count\_monthly\_model\_limit: type: integer format: int64 example: 500000 description: maximum number of reference data points that can be sent to a single model over a rolling 30 day period in the organization reference\_data\_count\_monthly\_total\_limit: type: integer format: int64 example: 500000 description: maximum number of reference data points that can be sent across all models over a rolling 30 day period in the organization reference\_data\_bytes\_per\_request\_limit: type: integer format: int64 example: 4294967296 description: maximum byte size of reference data that can be sent in a single request in the organization reference\_data\_bytes\_monthly\_model\_limit: type: integer format: int64 example: 68719476736 description: maximum byte size of reference data that can be sent to a single model over a rolling 30 day period in the organization reference\_data\_bytes\_monthly\_total\_limit: type: integer format: int64 example: 1099511627776 description: maximum byte size of reference data that can be sent across all models over a rolling 30 day period in the organization model\_versioning\_enabled: type: boolean example: false description: flag indicating whether model versioning is enabled in the organization enrichments\_enabled: type: boolean example: false description: flag indicating whether enrichments (explainability, hot-spots, etc.) are enabled in the organization tabular\_models\_only: type: boolean example: true description: flag indicating whether only tabular models are permitted in the organization ModelInsightCount: description: Insight counts by model properties: model\_id: type: string description: UUID of the model these insights belong to count: type: number description: number of insights that fit the request criteria InviteResponse: description: returned if and only if return\_direct\_links is set to true; returns a map of emails to invite links properties: user\_invite\_links: type: object description: a mapping where each email signup is a key and its corresponding signup invite link is the value + + diff --git a/files/arthur-docs-markdown/index.rst.txt b/files/arthur-docs-markdown/index.rst.txt new file mode 100644 index 0000000000000000000000000000000000000000..c52d494c5b77aa26545e5e980258f26264c3f211 --- /dev/null +++ b/files/arthur-docs-markdown/index.rst.txt @@ -0,0 +1,75 @@ +Arthur Docs Home +=========================================================== + +`Arthur `_ is the platform for centralized monitoring of production models. +We help data scientists, product owners, and business leaders accelerate model operations to optimize for accuracy, +explainability, and fairness. As a model- and infrastructure-agnostic platform, +Arthur adds a layer of intelligence to your AI stack and scales with your deployments. + +This documentation website is meant to help new users get started with Arthur, and to provide helpful +guides to existing users so they can get the most out of their production models with Arthur. + +For complete references for the Arthur API or the Python SDK, see our :doc:`API & SDK References `. + +.. container:: nav-card + + :doc:`Quickstart ` + +.. container:: nav-card + + :doc:`User Guide ` + +.. container:: nav-card + + :doc:`Platform Management ` + +.. container:: nav-card + + :doc:`API & SDK References ` + +***** + +======== +Contents +======== + + +:doc:`Arthur User Guide ` +*********************************************************** + +The Arthur User Guide contains everything you need to know to use the Arthur platform. If you're an Arthur end user, +start here. + +:doc:`Platform Management ` +*********************************************************** + +The Platform Management section contains information for Arthur product and infrastructure administrators, with guides +for on-prem deployments and organization management. + +:doc:`More Information ` +*********************************************************** + +Additional details about algorithms used in the Arthur platform, frequently asked questions, and a glossary of Arthur +terms. + +.. _API and SDK References: + +:doc:`API & SDK References ` +*********************************************************** +See our `Arthur REST API Reference `_ for a complete +outline of the endpoints available in the Arthur API. + +See our `Arthur Python SDK Reference `_ for a complete outline of the +functions available in the Arthur Python SDK. + +.. toctree:: + :hidden: + :maxdepth: 2 + + self + user-guide/index + platform-management/index + more-info/index + api-references + Example Projects + diff --git a/files/arthur-docs-markdown/internal/how-to-images.md.txt b/files/arthur-docs-markdown/internal/how-to-images.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3e2365694f8edefe8d408f8c2731d2260b776225 --- /dev/null +++ b/files/arthur-docs-markdown/internal/how-to-images.md.txt @@ -0,0 +1,19 @@ +--- +orphan: true +--- + +# Markdown Syntax + +All image use the same syntax regarding of the file extension. The structure is `[alt text][image path]` + +## Jpg +![.jpg image](https://uploads-ssl.webflow.com/5a749d2c4f343700013366d4/60772435a896b19234c5a7bb_maxresdefault-p-800.jpeg) + +## Gif +![.gif image](https://uploads-ssl.webflow.com/5a749d2c4f343700013366d4/607481fec86baf2a8cb273d8_monitor.gif) + +# HTML syntax + +We can also use regular HTML image tags if we want to add styling to our image. + +Alt text in case source link is broken \ No newline at end of file diff --git a/files/arthur-docs-markdown/more-info/FAQs.md.txt b/files/arthur-docs-markdown/more-info/FAQs.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..66f98c0ec6623a87236152a633538c754b880b42 --- /dev/null +++ b/files/arthur-docs-markdown/more-info/FAQs.md.txt @@ -0,0 +1,88 @@ +# FAQs + +**1. Can I use Arthur without using the Python SDK?** + +Yes! The Arthur platform is API-first. You can use our +[REST API](https://docs.arthur.ai/api-documentation/v3-api-docs.html) to onboard models, +send predictions, and query metrics and insights. +*** + +**2. Does Arthur need a copy of my model?** + +Arthur doesn’t generally need access to your actual model, but only captures the inputs to the model +and predictions it makes. This means that you can even use Arthur to monitor models you have no access to, +such as models hosted by third-party services. + +In order to enable explainability, Arthur _does_ need access to your model. +When {ref}`enabling this feature `, +you will need to provide access to the model's `predict` function. +*** + +**3. What if my data is proprietary? Can I still use Arthur?** + +Yes! Arthur offers on-premises installation for customers with data security requirements. By integrating Arthur +into your business's on-premises stack, you can be confident that all security requirements are met while still +getting the benefits of the computation and analytics Arthur provides. +*** + +**4. What if I don’t have ground truth labels for my data? Or what if I will have the ground truth labels in the future, +but they are not available yet?** + +You don't need ground truth labels to log your model's inferences with Arthur. + +If your ground truth labels become available after your model's inferences, whether seconds later or years later, +Arthur can link these new ground truth values to your model's past predictions, linking the new values by ID to +their corresponding inferences already in the Arthur system. + +In the meantime, Arthur’s data drift metrics can offer leading indicators of model underperformance to keep you +covered if your ground truth labels are delayed or never become available. +*** + +**5. I got an error using the SDK. What do I do?** + +If the error message says "an internal exception occurred, please report to Arthur" that means there was a problem +on our side. Please email the Arthur support team at `support@arthur.ai` to let us know what happened. + +Otherwise, the error message should provide helpful instructions for how to resolve the issue. If you don’t find +the error message actionable, please let Arthur know so that we can improve it. +*** + +**6. Do I have to type my credentials in every time I use the SDK?** + +No! Instead of manually entering them you can specify an `ARTHUR_ENDPOINT_URL` and `ARTHUR_API_KEY` +environment variable to be used to create the ArthurAI connection object. +*** + +**7. What are streaming and batch models?** + +{ref}`Streaming and batch models ` are two model types with different +patterns of ingesting data to send to Arthur. + +A streaming model processes data as a stream of individual inferences: data is logged with Arthur directly as +individual inferences when the data flows into the model. + +A batch model processes data as a sequence of grouped inferences, which are usually grouped over time: data is +logged with Arthur as a group of inferences as the model processes the batch. +*** + +**8. Which drift metric should I use?** + +Population stability index (PSI) is typically a good default drift metric to use. + +There are some cases where one wants a drift metric with a certain property, e.g. using a drift metric with the unit +nats for interpretability, or using a drift metric bounded between 0 and 1 so that drift values don't increase +arbitrarily for outliers. In these cases, other metrics may be preferable to PSI. + +For a review of the data drift metrics Arthur offers and their properties, see the +{ref}`data drift section of our glossary `. Furthermore, see +[our blog post](https://www.arthur.ai/blog/automating-data-drift-thresholding-in-machine-learning-systems) for an +overview of data how Arthur automates the choice of thresholding for drift metrics. + +**9. Do I need to configure my attribute ranges in order to onboard my model?** + +No - none of Arthur's model performance metrics or monitoring capabilities are impacted by the `range` property of an +attribute. So, if you observe the attribute looks off when you are reviewing your model during onboarding, you should feel fine +going ahead and saving your model to the platform. + +The `range` property of an attribute - the min/max values of numerical attributes - is only a measurement taken by +Arthur for making decisions on how to format plots in the online dashboard. diff --git a/files/arthur-docs-markdown/more-info/algorithms.md.txt b/files/arthur-docs-markdown/more-info/algorithms.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..8aa830e8074ef4ee83261f1610b1bc4443f28ceb --- /dev/null +++ b/files/arthur-docs-markdown/more-info/algorithms.md.txt @@ -0,0 +1,171 @@ +# Arthur Algorithms + +(arthur_algorithms_anomaly_detection)= +## Anomaly Detection + +For an explanation of how to enable Anomaly Detection with Arthur, please see the {ref}`enrichments guide `. + +Anomaly scores are computed by training a model on the reference set you provide to Arthur, and using that model to assign +an Anomaly Score to each inference you send to Arthur. Scores of 0.5 are given to "typical" examples from your reference +set, while higher scores are given to more anomalous inferences and lower scores are given to instances that the model +judges as similar to the reference data with high confidence. + +### How Anomaly Detection Works +We calculate Anomaly Scores with an Isolation Forest algorithm. This algorithm works by building what is essentially a density model of the data by iteratively isolating data points from one another. Because anomalies tend to be farther away from other points and occur less frequently, they are easier to isolate from other points, so we can use a data point's "ease of isolation" to describe its anomaly. The method is based on the paper linked [here](https://cs.nju.edu.cn/zhouzh/zhouzh.files/publication/icdm08b.pdf?q=isolation-forest). + +The Isolation Forest "method takes advantage of two [quantitative properties of anomalies]: + i) they are the minority consisting of fewer instances and + ii) they have attribute-values that are very different from those of normal instances. +In other words, anomalies are 'few and different', which make them more susceptible to isolation than normal points." + +The idea is to build a binary tree which randomly segments the data until each instance can be uniquely selected (or a maximum height is reached). Anomalous instances will take fewer steps to become isolated on the tree, because of the properties mentioned above. + +![iso-forest-example](/_static/images/iso-forest-example.png "ISO Forest Example") + +In the example above, we can see that the in-distribution $x_i$ takes many more steps to reach than the out-of-distribution $x_0$ + +Of course using a single randomly generated tree would be noisy. So we train multiple trees to construct an Isolation Forest of multiple trees and use the average path length, noting that average path lengths converge: + +![iso-forest-paths-converge](/_static/images/iso-forest-paths-converge.png "ISO Forest Path Convergence") + +The Isolation Forest algorithm is highly efficient compared to other density estimation techniques because the individual trees can be built from samples of the data without losing performance. + +When you add a reference set to your model in Arthur, we fit an Isolation Forest model to that data, so that we can compute an anomaly score for the inferences your model receives. + +### Generating Anomaly Scores + +The path length, or number of steps taken to reach the partition that a data point belongs to, varies between $0$ and $n-1$ where $n$ is the number of datapoints in the training set. Following our intuition above, the shorter the path length, the more anomalous a point is. In order to measure anomaly, an anomaly score between $0$ and $1$ is generated by normalizing the path length by the average path length and applying an inverse logarithmic scale. + +In particular, anomaly score $s(x,n) = 2^{-\frac{E(h(x))}{c(n)}}$, where $E(h(x))$ is the average path length to datapoint $x$from a collection of isolation trees and $c(n)$ is the average path length given the number of datapoints in the dataset $n$. + +Every inference you send to Arthur will be evaluated against the trained Isolation Forest model and given an anomaly score. + +This can be seen in the anomaly score contour of 64 normally distributed points: + +![iso-forest-contour](/_static/images/iso-forest-contour.png "ISO Forest Contours") + +At Arthur, we also visualize the distribution of anomaly scores among all of the inferences your model has retrieved since training. When you select an inference in our UI you'll see where it falls on this distribution: + +![anomaly-score-distribution](/_static/images/anomaly-score-distribution.png "Anomaly Score Distribution") + +### Interpreting Anomaly Scores + +The resulting anomaly scores can be interpreted in the following way: +- if instances return $s$ very close to $1$, then they are definitely anomalies +- if instances have $s$ smaller than $0.5$, then they are quite safe to be regarded as normal instances +- if all the instances return $s \approx 0.5$, then the entire sample does not really have any distinct anomaly + +----------- +(arthur_algorithms_bias_mitigation)= +## Bias Mitigation + +If you are interested in mitigation capabilities, we're happy to have a conversation about your needs and what approaches would work best for you. +Within the Arthur product, we offer postprocessing methods; we do encourage exploration of alternate (pre- or in- processsing) methods if your data science team has the bandwidth to do so. + +We currently have one postprocessing method available for use in the product: the Threshold Mitigator. + +### Threshold Mitigator +This algorithm is an extension of the Threshold Optimizer implemented in the `fairlearn` library, which in turn is based on Moritz Hardt's 2016 paper introducing the method. + +The intuition behind this algorithm is based on the idea that if the underlying black-box is biased, then different groups have different predicted probability distributions — let's call the original predicted probability for some example $x$ the score $s_x$. Then, for a *fixed threshold* $t$, $P(s_x > t | x \in A) > P(s_x > t | x \in B)$, where $B$ indicates membership in the disadvantaged group. For example, the default threshold is $t = 0.5$, where we predict $\hat Y = 1$ if $s > 0.5$. + +However, we might be able to **mitigate bias in the predictions by choosing group-specific thresholds for the decision rule.** + +So, this algorithm generally proceeds as follows: + +- Try every possible threshold $t$ from 0 to 1, where for any $x$, we predict $\hat Y = 1$ if and only if $s_x > t$. +- At each of those thresholds, calculate the group-specific positivity, true positive, and false positive rates. + +Let's say we're trying to satisfy demographic parity. We want the group-wise *positivity rates* to be equal — $P(\hat Y = 1 | A) = P(\hat Y = 1 | B)$. Then, for any given *positivity rate*, the threshold $t_a$ that achieves this positivity rate might be different from the threshold $t_b$ that achieves this positivity rate.  12* + +This also hints at why we need the notion of *tradeoff curves*, rather than a single static threshold: if we want to achieve a positivity rate of $0.3$, we'll need different $t_a, t_b$ than if we wanted to achieve a positivity rate of $0.4$. + +Then, once we've generated the curves, we pick a specific *point on the curve*, such as positivity rate of $0.3$. When making predictions on future and use the corresponding $t_a, t_b$ to make predictions + +#### What's Compatible? + +**Fairness constraints:** We can generate curves satisfying each of the following constraints (fairness metrics): + +- Demographic Parity (equal positivity rate) +- Equal Opportunity (equal true positive rate) +- Equalized Odds (equal TPR and FPR) + +**Sensitive attributes:** This algorithm can handle sensitive attributes that take on any number of discrete values (i.e. is not limited to binary sensitive attributes). For continuous sensitive attributes, we can specify buckets for the continuous values, then treat them like categorical attributes. + +#### The tradeoff curve + +**Generating the Curve** + +- Each *group* has its own curve. +- To generate a single curve, we generate all possible thresholds (i.e. `[0, 0.001, 0.002, 0.003, ..., 0.999, 1.00]`) — default 1000 total thresholds; as described above, for each of those thresholds, we calculate many common fairness metrics for the result *if* we were to use that threshold to determine predictions. + +**Visualizing the Curve** + +Depending on the fairness constraint we're trying to satisfy, the tradeoff curve will look different. +For equal opportunity and demographic parity, where there is a *single* quantity that must be equalized across the two groups, the tradeoff curve plots the quantity to equalize on the x-axis, and accuracy on the y-axis. + + + +**Understanding the Curve Artifact** + +The curve artifact can be pulled down according to our docs [here](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/bias-mitigation). This mitigation approach is somewhat constrained in the sense that we will generate a separate set of curves *for each sensitive attribute to mitigate on; for each constraint to follow.* Then, each *set* of curves entails a single curve for each sensitive attribute *value*. + +- Conceptually, the curves are organized something like the below; in the API, however, you'll be getting a single `< list of (x, y) coordinate pairs that define the curve >` at a time, with additional information about the attribute being mitigated; the constraint being targeted; and the feature value the specific list of pairs is for. + + ``` + **mitigating on gender -- demographic parity** + gender == male + < list of (x, y) coordinate pairs that define the curve > + gender == female + < list of (x, y) coordinate pairs that define the curve > + gender == nb + < list of (x, y) coordinate pairs that define the curve > + + **mitigating on gender -- equalized odds** + gender == male + < list of (x, y) coordinate pairs that define the curve > + gender == female + < list of (x, y) coordinate pairs that define the curve > + gender == nb + < list of (x, y) coordinate pairs that define the curve > + + **mitigating on age -- demographic parity** + age < 35 + < list of (x, y) coordinate pairs that define the curve > + age >= 35 + < list of (x, y) coordinate pairs that define the curve > + ``` + +**Summary of Curves by Constraint** + +- Equal opportunity (equal TPR): TPR vs accuracy; accuracy-maximizing solution is the point along the x-axis with the highest accuracy (y-axis) for both groups. +- Demographic parity (equal selection rates): selection rate vs accuracy; accuracy-maximizing solution is the point along the x-axis with the highest accuracy (y-axis) for both groups. +- Equalized odds (equal TPR *and* FPR): FPR vs TPR (canonical ROC curve); accuracy-maximizing solution is the point on the curves that are closest to the top left corner of the graph (i.e. low FPR and high TPR). + +#### Choosing a Set of Thresholds (Point on Curve) + +As mentioned above, a single "point" on the solution curve for a given constraint and sensitive attribute corresponds to several thresholds mapping feature value to threshold. But how do we choose which point on the curve to use? + +The default behavior — and, in fact, the default in fairlearn — is to automatically choose the accuracy-maximizing thresholds subject to a particular fairness constraint. This might work in most cases; however, accuracy is not necessarily the only benchmark that an end-user will care about. One client, for example, needs to satisfy a particular positivity rate, and is fine with sacrificing accuracy to do so. What our feature introduces that goes beyond what's available in fairlearn is the ability to try different thresholds; see what hypothetical predictions would be; and see what hypothetical results/metrics (eg positivity rate, TPR, etc) would look like *if* a certain set of thresholds was applied. Ultimate choice of thresholds is up to data scientists' needs, etc. + +--------- +(arthur_algorithms_hotspots)= +## Hotspots + + +For an explanation of how to enable Hotspots with Arthur, please see the {ref}`enrichments guide `. + +We might have a ML model deployed in production and some monitoring in place. We might notice that performance is degrading from classic performance metrics or from drift monitoring combined with explainability techniques. We’ve identified that our model is failing, and the next step is to identify why our model is failing. + +This process would involve slicing and dicing our input data that caused model degradation. That is, we want to see which particular input regions are associated with poor performance and work on a solution from there, such as finding pipeline breaks or retraining our models on those regions. + +This basically boils down to a time-consuming task of finding needles in a haystack. What if we could reverse engineer the process and surface all of the needles, i.e. input regions associated with poor performance, directly to the user? + +We can with Hotspots! + +### How Hotspots Works +The outputs of a model are encoded as a special classification task to partition data to separate out the poor performing datapoints from the correct predictions/classifications, on a per batch basis for batch models or on a per 7-day window for streaming models. + +Hotspot enrichments are used to surface input regions where the model is currently under performing on for inferences. Hotspots are extracted from a custom Arthur tree model, where nodes are associated with particular input regions and have associated performance metrics, e.g. a node with 70% accuracy that has datapoints where variable X is less than 1000. Nodes are candidates for hotspots. Depending on user-specified thresholds, e.g. a threshold of 71% accuracy, the tree is traversed until all nodes with less than 71%, such as our node with 70% accuracy, have been identified and returned to the user as hotspots, not including the hotspot nodes' children, which would be either (1) more pure than the hotspot node and therefore in further violation of the e.g. 71% threshold or (2) pure nodes with correct inferences, which are not of interest to the user for remediation purposes. + +For a more in depth overview, see our blog post [here](https://www.arthur.ai/blog/hotspots-automating-underperformance-regions-surfacing-in-machine-learning-systems). diff --git a/files/arthur-docs-markdown/more-info/glossary.md.txt b/files/arthur-docs-markdown/more-info/glossary.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..231b7d7446a811a4d6ea29f41d652eabbc9f2598 --- /dev/null +++ b/files/arthur-docs-markdown/more-info/glossary.md.txt @@ -0,0 +1,599 @@ +# Glossary + +The following definitions are specific to the Arthur platform, though in most cases are applicable to ML more broadly. + +## Arthur Inference +Container class for inferences uploaded to the Arthur platform. An inference is composed of input features, prediction values, and (optionally) ground truth values and any Non-Input data. + +Example: +```python +ground_truth = { + "Consumer Credit Score": 652.0 +} +inference = arthur_model.get_inference(external_id) +inference.update(ground_truth) +``` + +Related terms: [inference](#inference-data), [ArthurModel](#arthur-model) + +## Arthur Model +Model object used for sending and retrieving data pertinent to a deployed ML system. The `ArthurModel` object is separate from the underlying model that is trained and which makes predictions; it serves as a wrapper for the underlying model to access Arthur platform functionality. + +An ArthurModel contains at least a `name`, an `InputType` and a `OutputType`. + +Examples: +```python +arthur_model = connection.model(name="New_Model", + input_type=InputType.Tabular, + model_type=OutputType.Regression) +``` + +```python +arthur_model = connection.get(model_id) +arthur_model.send_inference(...) +``` + +## Arthur Model Group + +Arthur Model Groups are an organizational construct the Arthur platform uses to track different versions of an Arthur model. Every Arthur Model is a version of one Model Group and a Model Group will always have at least one Arthur Model. The Model Group for an Arthur Model can only be specified during on-boarding, and once the Arthur Model is saved, its group cannot be changed. If an Arthur Model is created without specifying a Model Group, a new Model Group will be created automatically with the new model as its single version. When adding a model to a model group, the model is assigned a unique, incrementing Version Sequence Number (starting at 1) corresponding to the order in which it was added to the model group. Additionally, you can provide a Version Label to store a custom version string label along with the Version Sequence Number. + +Example: + +```python +# retrieve the first version of a model +arthur_model_v1 = connection.get(model_id) +model_group = arthur_model_v1.model_group + +# create the new version of the model +arthur_model_v2 = connection.model(name="Model_V2", + input_type=InputType.Tabular, + model_type=OutputType.Regression) + +# add the new model to the model group +model_group.add_version(arthur_model_v2, label="2.0.1") +arthur_model_v2.save() +``` + +Related terms: [Version Label](#version-label), [Version Sequence Number](#version-sequence-number) + +## Attribute +A variable associated with a model. Can be input, prediction, ground truth or ancillary information (these groupings are known as [Stages](#stage) in the Arthur platform). Can be categorical or continuous. +Example: +> The attribute `age` is an input to the model, whereas the attribute `creditworthy` is the target for the model. + +Synonyms: variable, {predictor, input}, {ouput, target}, prediction. + +Related terms: [input](#input), [stage](#stage), [prediction](#prediction), [ground truth](#ground-truth) + + +## Bias +While bias is an overloaded term in stats&ML, we refer specifically to where a model's outcomes have the potential to differentially harm certain subgroups of a population. + +Example: +> This credit approval model tends to lead to biased outcomes: men are approved for loans at a rate 50% higher than women are. + + +Related terms: [bias detection](#bias-detection-a-name-bias-detection-a), [bias mitigation](#bias-mitigation-a-name-bias-mitigation-a), [disparate impact](#disparate-impact-a-name-disparate-impact-a) + + +## Bias Detection +The detection and quantification of {doc}`algorithmic bias ` in an ML system, typically as evaluated on a model's outputs (predictions) across different populations of a sensitive attribute. +[Many definitions](http://fairware.cs.umass.edu/papers/Verma.pdf) of algorithmic bias have been proposed, including group fairness and individual fairness defintions. +Group fairness definitions are often defined by comparing group-conditional statistics about the model's predictions. +In the below definitions, the group membership feature is indicated by $G$ and a particular group membership value is indicated by $g$. + +Example: +> Common metrics for group fairness include Demographic Parity, Equalized Odds, and Equality of Opportunity. + +Related terms: [bias mitigation](#bias-mitigation) + +### Demographic Parity + +A fairness metric which compares group-conditional selection rates. The quantity being compared is: + +$$ +\begin{align*} +\mathbb P(\hat Y = 1 | G = g) +\end{align*} +$$ + +There is not necessarily a normative ideal relationship between the selection rates for each group: +in some situations, such as the allocation of resources, it may be important to minimize the disparity +in selection rates across groups; in others, metrics based on group-conditional accuracy may be more relevant. +However, even in the latter case, understanding group-conditional selection rates, especially when +compared against the original training data, can be useful contextualization for the model and its task as a whole. + +Related term: [disparate impact](#disparate-impact-a-name-disparate-impact-a) + +### Equal Opportunity + +A fairness metric which compares group-conditional true positive rates. The quantity being compared is: + +$$ +\begin{align*} +\mathbb P(\hat Y = 1 | Y = 1, G = g) +\end{align*} +$$ + +For all groups, a true positive rate closer to 1 is better. + +### Equalized Odds + +A fairness metric which incorporates both group-conditional true positive rates and false positive rates, +or, equivalently, true positive rates and true negative rates. There are a variety of implementations (due +to the fact that some quadrants of the confusion matrix are complements of one another); here is one possible quantity to compare across groups: + +$$ +\begin{align*} +\mathbb P (\hat Y = 1 | Y = 1, G = g) + \mathbb P(\hat Y = 0 | Y = 0, G = g) +\end{align*} +$$ + +In this implementation, this quantity should be as close to 2 as possible for all groups. + + +## Bias Mitigation +Automated techniques to mitigating bias in a discriminatory model. Can be characterized by where the technique sits in the model lifecycle: + * **Pre-Processing**: Techniques that analyze datasets and often modify/resample training datasets so that the learned classifier is less discriminatory. + * **In-Processing**: Techniques for training a fairness-aware classifier (or regressor) that explicitly trades off optimizing for accuracy and also maintaining fairness across sensitive groups. + * **Post-Processing**: Techniques that only adjust the output predictions from a discriminatory classifier, without modifying the training data or the classifier. + +Related terms: [bias detection](#bias-detection) + + + + +## Binary Classification +A modeling task where the target variable belongs to a discrete set with two possible outcomes. + +Example: +> This binary classifier will predict whether or not a person is likely to default on their credit card. + + +Related terms: [output type](#output-type), [classification](#classification), [multilabel classification](#multilabel-classification) + + + +## Categorical Attribute +An attribute whose value is taken from a discrete set of possibilities. + +Example: +> A person's blood type is a categorical attribute: it can only be A, B, AB, or O. + +Synonyms: discrete attribute + +Related terms: [attribute](#attribute), [continuous](#continuous-attribute), [classification](#classification) + +## Classification +A modeling task where the target variable belongs to a discrete set with a fixed number of possible outcomes. + +Example: +> This classification model will determine whether an [input](#input) image is of a cat, a dog, or fish. + +Related terms: [output type](#output-type), [binary classification](#binary-classification), [multilabel classification](#multilabel-classification) + +## Continuous Attribute +An attribute whose value is taken from an ordered continuum, which can be bounded or unbounded. + +Example: +> A person's height, weight, income, IQ can all be through of as continuous attributes. + +Synonyms: numeric attribute + +Related terms: [attribute](#attribute), [continuous](#continuous-attribute), [regression](#regression) + +(glossary_custom_role)= +## Custom Role +Custom Roles are a resource in the Arthur platform used for managing access control policies when SSO authentication has been enabled. For more instructions on configuring Custom Roles, view the {doc}`custom authorization documentation section `. + +(glossary_data_drift)= +## Data Drift +Refers to the problem arising when, after a trained model is deployed, changes in the external world lead to degradation of model performance and the model becoming stale. Detecting data drift will provide a leading indicator about data stability and integrity. + +Data drift can be quantified with respect to a specific reference set (eg. the model's training data), or more generally over any temporal shifts in a variable with respect to past time windows. + +Your project can {doc}`query data drift metrics through the Arthur API `. This section will provide overview of the available data drift metrics in Arthur's query service. + +Related terms: [out of distribution](#ood-detection) + +### Definitions + +#### P and Q + +We establish some mathematical housekeeping for the below metrics. Let $P$ be the reference distribution and $Q$ be the target distribution. These are both probability distributions that can be approximated by binning the underlying reference and target sets. Generally, $P$ is an older dataset and $Q$ is a new dataset of interest. We'd like to quantify how far the distributions differ to see if the reference set has gone stale and algorithms trained on it should not be used to perform inferences on the target dataset. + +#### Entropy + +Let $\text{H}(P)$ be the entropy of distribution $P$. It is interpreted as the expected (i.e. average) number of bits (if log base 2) or nats (if log base $e$) required to encode information of a datapoint from distribution $P$. Arthur applications use log base $e$, so interpretation will be in nats. + +$$ +\begin{align*} +\text{H}(P) += -\sum_{k=1}^K P(x_k)*\text{log}P(x_k) += -\text{E}_P[\text{log}P(x_k)] +\end{align*} +$$ + +### KL Divergence + +Let $\text{D}(P \parallel Q)$ be the Kullback-Leibler (KL) Divergence from $P$ to $Q$. It is interpreted as the nats of information we expect to lose in using $Q$ instead of $P$ for modeling data $X$, discretized over probability space $K$. KL Divergence is not symmetrical, i.e. $\text{D}(P \parallel Q) \neq \text{D}(Q \parallel P)$, and should not be used as a distance metric. + +$$ +\begin{align*} +\text{D}(P||Q) += \sum_{k=1}^K P(x_k)*(\text{log}P(x_k)-\text{log}Q(x_k)) \\ += \text{E}_P[\text{log}P(x)-\text{log}Q(x)] +\end{align*} +$$ + +### Population Stability Index (PSI) + +Let $\text{PSI}(P,Q)$ be the Population Stability Index (PSI) between $P$ and $Q$. It is interpreted as the roundtrip loss of nats of information we expect to lose from $P$ to $Q$ and then from $Q$ returning back to $P$, and vice versa. PSI smooths out KL Divergence since the return trip information loss is included, and this metric is popular in financial applications. + +$$ +\begin{align*}\text{PSI}(P,Q) += \text{D}(P||Q) + \text{D}(Q||P) \\ += \sum_{k=1}^K (P(x_k)-Q(x_k))*(\text{log}P(x_k)-\text{log}Q(x_k)) \\ += \text{E}_P[\text{log}P(x)-\text{log}Q(x)]+\text{E}_Q[\text{log}Q(x)-\text{log}P(x)] +\end{align*} +$$ + +### JS Divergence + +Let $\text{JSD}(P,Q)$ be the Jensen-Shannon (JS) Divergence between $P$ and $Q$. It smooths out KL divergence using a mixture of the base and target distributions and is interpreted as the entropy of the mixture $M=\frac{P+Q}{2}$ minus the mixture of the entropies of the individual distributions. + +$$ +\begin{align*}\text{JSD}(P,Q) += \frac{1}{2}\text{D}(P||M) + \frac{1}{2}\text{D}(Q||M) \\ += \text{H}(\frac{P+Q}{2})-\frac{\text{H}(P)+H(Q)}{2} +\end{align*} +$$ + +### Hellinger Distance + +Let $\text{HE}(P,Q)$ be the Hellinger Distance between $P$ and $Q$. It is interpreted as the Euclidean norm of the difference of the square root distributions of $P$ and $Q$. + +$$ +\begin{align*} +\text{HE}(P,Q) += {\frac {1}{\sqrt {2}}}{\bigl \|}{\sqrt {P}}-{\sqrt {Q}}{\bigr \|}_{2} \\ += {\frac {1}{\sqrt {2}}}{\sqrt {\sum _{k=1}^{K}\left({\sqrt {P(x_k)}}-{\sqrt {Q(x_k)}}\right)^{2}}} +\end{align*} +$$ + +(glossary_hypothesis_test)= +### Hypothesis Test + +Hypothesis testing uses different tests depending on whether a feature is categorical or continuous. + +For categorical features, let $\chi_{\text{K}-1}^2(P,Q)$ be the chi-squared test statistic for $P$ and $Q$, with $\text{K}$ being the number of categories of the feature, i.e. $\text{K}-1$ are the degrees of freedom. Let $\text{N}_{Pk}$ and $\text{N}_{Qk}$ be the count of occurrences of feature being $k$, with $1\leq k \leq K$, for $P$ and $Q$ respectively. The chi-squared test statistic is the summation of the standardized differences of expected counts between $P$ and $Q$. + +$$ +\begin{align*} +\chi_{K-1}^2(P,Q) += \sum_{k=1}^K \frac{(\text{N}_{Qk}-\text{N}_{Pk})^2}{\text{N}_{Pk}}\\ +\end{align*} +$$ + +For continuous features, let $\text{KS}(P, Q)$ be the Kolmogorov-Smirnov test statistic for $P$ and $Q$. Let $F_P$ and $F_Q$ be the empirical cumulative density, for $P$ and $Q$ respectively. The Kolmogorov-Smirnov test is a nonparametric, i.e. distribution-free, test that compares the empirical cumulative density functions of $P$ and $Q$. + +$$ +\begin{align*} +\text{KS}(P,Q) += \sup_x (F_P(x) - F_Q(x)) \\ +\end{align*} +$$ + +The returned test statistic is then compared to cutoffs for significance. A higher test statistic indicates more data drift. We've abstracted the calculations away for you in our query endpoint. + +For `HypothesisTest`, the returned value is transformed as -log_10(P_value) to maintain directional parity with the other data drift metrics. That is, lower P_value is more significant and implies data drift, reflected in a higher -log_10(P_value). + +### Multivariate + +Arthur also offers a multivariate Anomaly Score which you can configure via the steps detailed {ref}`here `. +See {ref}`here ` for an explanation of how these scores are calculated. + +## Disparate Impact +Legal terminology orginally from Fair Lending case law. This constraint is strictly harder than [Disparate Treatment](#disparate-treatment) and asserts that model outcomes must not be discriminatory across protected groups. That is, the outcome of a decisioning process should not be substantially higher (or lower) for one group of a protected class over another. + +While there does not exist a single threshold for establishing the presence or absence of disparate impact, the so-called ["80% rule"](https://www.eeoc.gov/laws/guidance/questions-and-answers-clarify-and-provide-common-interpretation-uniform-guidelines) is commonly referenced. However, we strongly recommend against adopting this rule-of-thumb, as these analyses should be grounded in use-case specific analysis and the legal framework pertinent to a given industry. + +Example: +> Even though the model didn't take `gender` as input, it still results in disparate impact when we compare outcomes for males and females. + +Related terms: [bias](#bias), [disparate treatment](#disparate-treatment) + + +## Disparate Treatment +Legal terminology originally from Fair Lending case law. Disparate Treatment asserts that you are not allowed to consider protected variables (eg race, age, gender) when approving or denying an applicant for a credit card loan. +In practical terms, this means that a data scientist cannot include these attributes as [inputs](#input) to a credit decisioning model. + +Adherence to Disparate Treatment is not a sufficient condition for actually acheiving a fair model (see [proxy](#proxy) and [bias detection](#bias-detection)). "Fairness through unawareness" is not good enough. + +Related terms: [bias](#bias), [disparate impact](#disparate-impact) + +## Enrichment +Generally used to describe data or metrics added to raw data after ingestion. Arthur provides various enrichments such as Anomaly Detection and Explainability. See {doc}`/user-guide/walkthroughs/enrichments` for details around using enrichments within Arthur. + +## Feature +An individual attribute that is an input to a [model](#arthur-model) + +Example: +> The credit scoring model has features like `“home_value”`, `“zip_code”`, `“height"`. + +## Ground Truth +The true label or target-variable (Y) corresponding to inputs (X) for a dataset. + + +Examples: + ``` +pred = sklearn_model.predict_proba(X) +arthur_model.send_inference( + model_pipeline_input=X, + predicted_values={1:pred, 0: 1-pred}) +``` + +Related terms: [prediction](#prediction) + + +## Image Data +Imagery data commonly used for computer vision models. + +Related terms: [attribute](#attribute), [output type](#output-type), [Stage](#stage) + + + +## Inference +One row of a dataset. An inference refers to passing a single input into a model and computing the model's prediction. Data associated with that inference might include (1) input data, (2) model's prediction, (3) corresponding ground truth. +With respect to the Arthur platform, the term inference denotes any and all of those related components of data for a single input&prediction. + + +Related terms: [ArthurInference](#arthur-inference), [stage](#stage) + + + +## Input +A single instance of data, upon which a model can calculate an output [prediction](#prediction). The input consists of all relevant [features](#feature) together. + +Example: +> The input features for the credit scoring model consist of `“home_value”`, `“zip_code”`, `“height"`. + +Related terms: [feature](#feature), [model](#arthur-model) + +## Input Type +For an [ArthurModel](#arthur-model), this field declares what kind of input datatype will be flowing into the system. + +Allowable values are defined in the `InputType` enum: +* [`Tabular`](#tabular-data) +* [`Image`](#image-data) +* [`NLP`](#nlp-data) + +Example: +```python +arthur_model = connection.model(name="New_Model", + input_type=InputType.Tabular, + model_type=OutputType.Regression) +``` + +Related terms: [output type](#output-type), [tabular data](#tabular-data), [nlp data](#nlp-data) + + + +## Model Health Score +On the UI dashboard, you will see a model health score between 0-100 for each of your models. +The score is an aggregation based on the following metrics: performance, drift and ingestion. +Each metric for a model is computed every hour, combined, and then aggregated by computing the average over a 30-day window. +The thresholds for model-health are (0-32, 33-65, 66-100) for (Red, Yellow, Green) respectively. + +* Performance: + * Regression: 1 - Normalized MAE + * Classification: F1 Score + +* Drift + * 1 - Average Anomaly Score + +* Ingestion + * Variance of normalized time periods between ingestion events + * Variance of normalized volume differences between ingestion events + + +You can extract the health score via an API [call](../api-documentation/v3-api-docs.html#tag/models/paths/~1models~1health/get) as well. + + +## Model Onboarding +Model onboarding refers to the process of defining an `ArthurModel`, preparing it with the necessary reference dataset, passing it through a validation check, and saving it to the Arthur system. + +Once your model is onboarded onto Arthur, you can use the Arthur system to track the model and view all its performance and analytics in your online Arthur dashboard. + +Related terms: [ArthurModel](#arthur-model), [reference dataset](#reference-data) + + +## Multiclass Classification +A modeling task where each [input](#input) is associated with one label, from a fixed set of possible labels. +Often this is a binary classifier (the output is either 0 or 1), but the output can also have more than 2 possible labels. + +Example: +> This NLP model applies the most relevant tag to news articles. The model is trained on example articles which are tagged with a topic like `Congress`. + +Related terms: [multilabel clasification](#multilabel-classification), [output type](#output-type), + + +## Multilabel Classification +A modeling task where each [input](#input) is associated with two or more labels, from a fixed set of possible labels. + +Example: +> This NLP model applies relevant tags to news articles. The model is trained on example articles which are tagged with multiple topics like `Politics, Elections, Congress`. + +Related terms: [output type](#output-type), [multiclass clasification](#multiclass-classification) + + +## NLP Data +Unstructured text sequences commonly used for Natural Language Processing models. + +Related terms: [attribute](#attribute), [output type](#output-type), [Stage](#stage) + + +## Non-Input Attribute + +A non-input attribute is an attribute that an ArthurModel will track that does not actually enter the model as an input. + +Common non-input attributes are protected class attributes such as age, race, or sex. By sending such non-input attributes to Arthur, you can track model performance based on these groups in your data to evaluate model bias and fairness. + +Related terms: [attribute](#attributea-nameattributea), [bias](#biasa-namebiasa) + + +## Object Detection +The OutputType for computer vision models with the purpose of detecting an object within an image and outputting a box which bounds the object. + +This bounding box is used to identify _where_ the object resides in the image. + +Related terms: [image](#image-dataa-nameimage-dataa) + +(glossary_organization)= +## Organization +An Organization is a structural entity utilized by the Arthur platform to organize and manage access to resources that exist on the platform. Users are added to Arthur Organizations with a given role that provides them with Read and/or Write access to some subset of that Organization's resources, as defined by the User's role. + +Each Organization has its own: +- [Models](#arthur-modela-namearthur-modela) +- [Model Groups](#arthur-model-groupa-namearthur-model-groupa) +- [Service Accounts](#service-accounta-nameservice-accounta) +- {ref}`Custom Roles ` + +## Out of Distribution Detection +Refers to the challenge of detecting when an input (or set of inputs) is substantially different from the distribution of a larger set of reference inferences. This term commonly arises in the context of data drift, where we want to detect if new inputs are different from the training data (and distribution thereof) for a particular model. OOD Detection is a relevant challenge for Tabular data as well as unstructured data such as images and sequences. + + +Related terms: {ref}`glossary_data_drift` + +## Output Type +For an [ArthurModel](#arthur-model), this field declares what kind of output predictions will be flowing out of the system. + +Allowable values are defined in the `OutputType` enum: + * [`Regression`](#regression) + * appropriate for continuous-valued targets + * [`Multiclass`](#classification) + * appropriate for both binary classiers and multiclass classifiers + * [`Multilabel`](#multilabel-classification) + * appropriate for multilabel classifiers + * [`ObjectDetection`](#object-detection) + * only available for computer vision models + +Example: +```python +arthur_model = connection.model(name="New_Model", + input_type=InputType.Tabular, + output_type=OutputType.Regression) +``` + + +Related terms: [input type](#input-type) + +## Prediction +The output prediction (y_hat) of a trained model for any input. + +Related terms: [ground truth](#ground-truth) + +## Protected Attribute +An attribute of an inference that is considered sensitive with respect to model bias. Common examples include race, age, and gender. The term "protected" comes from the Civil Rights Act of 1964. + +Synonyms: sensitive attribute + +Related terms: [bias](#bias), [proxy](#proxy) + + +## Proxy +An input attribute in a model (or combination thereof) that is highly correlated with a protected attribute such as race, age, or gender. The presence of proxies in a dataset makes it difficult to rely only on [Disparate Treatment] as a standard for fair ML. + +Example: +> In most US cities, zip code is a strong proxy for race. Therefore, one must be cautious when using zip code as an input to a model. + +Related terms: [bias](#bias), [disparate impact](#disparate-impact), [disparate treatment](#disparate-treatment) + + +## Reference +The dataset used as a baseline reference for an ArthurModel. + +A reference dataset must include a sample of the input features a model receives. + +A reference dataset can optionally include a sample of model outputs, ground truth values, and other non-input attributes as metadata. + +The reference dataset for a model is used to compute drift: the distribution of input features in the reference dataset makes up the baseline against which future inferences are compared to compute anomaly scores. + +Related terms: [inference](#inference) + +## Regression +A modeling task (or model) where the [target variable](#ground-truth) is a continuous variable. + +Example: +> This regression model predicts what the stock price of $AAPL will be tomorrow. + +Related terms: [output type](#output-type) + +## Sensitive Attribute +See [protected attribute](#protected-attribute) + +## Service Account +Service Accounts are entities within the Arthur Platform that provide access to Arthur APIs for automated systems (machine-to-machine communication). They represent both an identity as well as a set of permissions for that identity. Each Service Account has an access token that includes a specific role, which grants access to the Arthur APIs. The roles used in Service Accounts provide access within a single Arthur {ref}`Organization `. + +## Stage +Taxonomy used by the Arthur platform to delineate how [attributes](#attribute) contribute to the model computations. +Allowable values are defined in the `Stage` enum: + * `ModelPipelineInput` : Input to the entire model pipeline. This will most commonly be the Stage used to represent all model inputs. Will contain base input features that are familiar to the data scientist: categorical and continuous columns of a tabular dataset. + * `PredictedValue`: The predictions coming out of the model. + * `GroundTruth`: The ground truth (or target) attribute for a model. Must be one-hot for classifiers + * `GroundTruthClass`: The ground truth class for classification models, not one-hot encoded + * `NonInput`: Ancillary data that can be associated with each inference, but not necessarily a direct input to the model. For example, sensitive attributes like `age`, `sex`, or `race` might not be direct model inputs, but will useful to associate with each prediction. + +## Tabular Data +Data type for model inputs where the data can be thought of as a table (or spreadsheet) composed of rows and columns. Each column represents an input [attribute](#attribute) for the model and each row represents a separate record that composes the training data. In supervised learning, exactly one of the columns acts as the [target](#ground-truth). + +Example: +> This credit scoring model is trained on tabular data. The [input](#input) attributes are `income`, `country`, and `age` and the [target](#ground-truth) is FICO score. + + +Related terms: [Attribute](#attribute), [output type](#output-type), [Stage](#stage) + +## Version Label + +A Version Label is a string that can represent a custom version for your Arthur Model within its Arthur Model Group. Version Labels are not required and the platform will default to using the Version Sequence Number when not provided. + +Example: + +```python +# retrieve the model group +model_group = connection.get_model_group(model_group_id) + +# create the new version of the model +arthur_model_v2 = connection.model(name="Model_V2", + input_type=InputType.Tabular, + model_type=OutputType.Regression) + +# add the new model to the model group +model_group.add_version(arthur_model_v2, label="2.0.1") +label = arthur_model_v2.version_label +arthur_model_v2.save() +# label == "2.0.1" +``` + +Related terms: [Arthur Model](#arthur-model), [Arthur Model Group](#arthur-model-group), [Version Sequence Number](#version-sequence-number) + +## Version Sequence Number + +A Version Sequence Number is a unique, auto-incrementing (starting at 1) integer that is assigned to Arthur Models in an Arthur Model Group. This number uniquely represents an Arthur Model’s Version within the Model Group. In the case a Version Label is not provided, the platform will show the Version Sequence Number instead. + +Example: + +```python +# retrieve the first version of a model +arthur_model_v1 = connection.get(model_id) +num = arthur_model_v1.version_sequence_num +# num == 1 + +# retrieve the second version of a model +model_group = arthur_model_v1.model_group +arthur_model_v2 = model_group.get_version(sequence_num=2) +num = arthur_model_v2.version_sequence_num +# num == 2 +``` + +Related terms: [Arthur Model](#arthur-model), [Arthur Model Group](#arthur-model-group), [Version Label](#version-label) diff --git a/files/arthur-docs-markdown/more-info/index.md.txt b/files/arthur-docs-markdown/more-info/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..9ce99dec4dc6bdc95f234d2f274cdc5ded791615 --- /dev/null +++ b/files/arthur-docs-markdown/more-info/index.md.txt @@ -0,0 +1,26 @@ +# More Information + +## {doc}`algorithms` + +The {doc}`algorithms` page describes the math behind the algorithms Arthur implements for +calculating performance-related metrics and insights for your models. + +## {doc}`FAQs` + +Visit our {doc}`FAQs` page to see answers to common questions about Arthur and model +monitoring. + +## {doc}`glossary` + +Our {doc}`glossary` contains a definition of terms used throughout the Arthur documentation, as well as +related links to other terms and guides to get familiar with Arthur. + + +```{toctree} +:maxdepth: 2 +:hidden: + +Arthur Algorithms +FAQs +Glossary +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/not-found.rst.txt b/files/arthur-docs-markdown/not-found.rst.txt new file mode 100644 index 0000000000000000000000000000000000000000..593c06780a8c8afb348130122259fede95797afb --- /dev/null +++ b/files/arthur-docs-markdown/not-found.rst.txt @@ -0,0 +1,6 @@ +:orphan: + +Not Found +========= + +The page you're looking for wasn't found. diff --git a/files/arthur-docs-markdown/platform-management/.DS_Store b/files/arthur-docs-markdown/platform-management/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..f43a53b166e469e0009f8324c4652e348fdc9252 Binary files /dev/null and b/files/arthur-docs-markdown/platform-management/.DS_Store differ diff --git a/files/arthur-docs-markdown/platform-management/access-control-overview/index.md.txt b/files/arthur-docs-markdown/platform-management/access-control-overview/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..519cfc27fd5af27752e84b617a1bec7b3adde44c --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control-overview/index.md.txt @@ -0,0 +1,43 @@ +# Access Control Overview + +Arthur has supports a variety of mechanisms for authentication, who a user is, and authorization, what a user can do +(RBAC). +By default, Arthur will use a built-in authentication and authorization system. In on-prem installations, cluster +administrators can optionally configure an external Identity Provider (IdP) to control user authentication and +authorization. See the sections below for an overview of Arthur Standard Access Control and Arthur SSO Access Control. + +## {doc}`Arthur Standard Access Control ` + +The {doc}`Arthur Standard Access Control ` page shows how to use the default access control +system in Arthur. + +## {doc}`Single-Sign-On (SSO) Access Control ` (On-prem only) + +The {doc}`Single-Sign-On (SSO) Access Control ` page shows how to set up and use an external +IdP for access +control. + +## Access Control Paradigm Comparison + +The following table shows a high level comparison of the different capabilities in +{doc}`Arthur Standard Access Control ` +and {doc}`Arthur SSO Access Control `. + +| Capability | Arthur Standard Access Control | SSO Access Control | +|--------------------------------------------------------|--------------------------------|----------------------------| +| User creation | In the Arthur UI | In the IdP | +| User sign-in | In the Arthur UI | In the IdP | +| User password reset | In the Arthur UI | In the IdP | +| Can use Arthur API Keys | Yes | No | +| Supports Custom Roles and RBAC | No | Yes | +| Users can have access to multiple Arthur organizations | Yes | Yes | +| Availability | All Arthur installations | On-prem only | +| Required permissions to configure | Organization Admin | Installation/Cluster Admin | + +```{toctree} +:maxdepth: 2 +:hidden: + +Default Access Control +SSO Access Control +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/custom_rbac.md.txt b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/custom_rbac.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..47f82ce2a2585aebe51195ae136ec549c70fe5bb --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/custom_rbac.md.txt @@ -0,0 +1,133 @@ +# Custom RBAC + +(custom_rbac_managing_orgs_and_roles)= +## Managing RBAC and Organizations for SSO users + +For customers using SSO (on-prem only), Arthur provides the ability to set up a fully customizable RBAC. +Please follow the below: + +1. When setting up your identity provider via the YAML configuration, supply a global + role name and set of permissions under `globalRoleDefs` that your identity provider will authenticate users with. + This configuration will create the global role in the Arthur authorization system when it is applied. See the + {ref}`Creating Global Roles for Managing Organizations and RBAC Policies Guide ` for + more information. +2. That global role can then create custom role mappings for each organization: + * During organization creation, include the role configuration JSON (see below for example) in the request body when + calling [`POST /organizations`](../../../../api-documentation/v3-api-docs.html#tag/organizations/paths/~1organizations/post). + * After an organization is created, create or add custom_roles by sending the role configuration JSON (see below for + example) in the request body when + calling [`POST /autorization/custom_roles`](../../../../api-documentation/v3-api-docs.html#tag/authorization/paths/~1authorization~1custom_roles/post). +3. Users logging in through your IdP must now have a valid known role in their token when accessing the Arthur + Platform. Arthur will use this role to both authenticate that the user is a member of the organization and to + determine the permissions they have. + +## Managing Roles and Permissions + +### Understanding Permissions + +* A permission is a combination of a resource and an action. For + example `raw_data read`, `users write`, `models delete`. +* For a full list of available permissions. please see {doc}`here `. +* For a directory of permissions by API endpoint, please see + {doc}`here `. + +### Create Custom Roles + +The [`POST /autorization/custom_roles`](../../../../api-documentation/v3-api-docs.html#tag/authorization/paths/~1authorization~1custom_roles/post) +endpoint is available for customers using SSO to operate on custom roles for each organization. A few notes: + +* This endpoint only operates on permission scopes within each organization. Permissions that have global scope (such as + creating a new organization) cannot be granted via this endpoint, those permissions must be assigned to a role with + global privileges via the Arthur IdP configuration YAML. See + {ref}`Creating Global Roles for Managing Organizations and RBAC Policies Guide ` for more + information. +* Roles can have a list of permissions to allow and/or a list of other roles to inherit permissions from. +* Role names cannot conflict with {doc}`default roles `. +* Supplied permissions must be valid known Arthur permissions. +* Roles can inherit the permissions of other roles that are either + {doc}`default roles `, or roles also defined in the same + organization. Unknown inherited role names will be rejected. + +### Get Custom Roles + +To retrieve a list of roles defined for an organization, +use: [`GET /autorization/custom_roles`](../../../../api-documentation/v3-api-docs.html#tag/authorization/paths/~1authorization~1custom_roles/get). +To filter on specific roles pass a comma separated list of role names in a roles query parameter. For +example:`/authorization/custom_roles?roles=role1,role2`. If you wish to return all roles simply leave out the query +parameter or pass `"*"` as role. + +### Delete Custom Roles + +To delete a role or multiple roles from an organization, +use [`DELETE /autorization/custom_roles`](../../../../api-documentation/v3-api-docs.html#tag/authorization/paths/~1authorization~1custom_roles/delete). +Specify which roles to delete in the JSON request body. For example, to delete a single role: + +```json +{ + "roles": [ + "role3" + ] +} +``` + +To delete all roles pass "*". + +```{warning} If you do not specify an organization_id, this will delete all custom roles you have created +``` + +```json +{ + "roles": [ + "*" + ] +} +``` + +### Example Role Configuration JSON + +Below is an example JSON request body that creates three roles. role1 has 3 permissions defined, role2 gets an +additional permission and then inherits the 3 permissions from role1, and role3 inherits the permissions from Arthur's +default "Model Owner" role. For more details on the expected schema for each endpoint, +see [Authorization API documenation](../../../../api-documentation/v3-api-docs.html#tag/authorization). + +```json +{ + "roles": [ + { + "role_name": "role1", + "permissions": [ + { + "resource": "metric_data", + "action": "read" + }, + { + "resource": "metric_data", + "action": "write" + }, + { + "resource": "tag", + "action": "read" + } + ] + }, + { + "role_name": "role2", + "permissions": [ + { + "resource": "user_self", + "action": "read" + } + ], + "inherited_role_names": [ + "role1" + ] + }, + { + "role_name": "role3", + "inherited_role_names": [ + "Model Owner" + ] + } + ] +} +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/index.md.txt b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a9a7acfc4051b497e5ca62965ed815a9ba1131ab --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/index.md.txt @@ -0,0 +1,322 @@ +# Arthur SSO Access Control Overview + +In on-prem installations, cluster administrators have the ability to configure their Arthur install to use a 3rd party +identity provider (IdP) to manage Arthur users and access. Arthur can work with any IdP that supports the Open ID +Connect (OIDC) or SAML protocols. + +## User and App Authentication + +Regardless of if your IdP is using OIDC or SAML, the IdP will be responsible for authenticating users and system access +to Arthur. As a result, applications or downstream systems that need to authenticate with Arthur will require working +with your IdP to get access. Some IdPs provide support for AppID's or service accounts, but it will depend on the +specific IdP and how your organization supports it. + +```{warning} +Important! Arthur API keys cannot be used when SSO in enabled. +Instead, users will rely on their own authentication tokens, which are validated by the IdP and enforce the custom +permissions assigned to their roles. +``` + +## Authorization (RBAC) + +Arthur installations with SSO are able to use custom role-based access control policies (RBAC) for +users authenticated via the IdP. Arthur's custom RBAC system uses two kinds of roles. The first kind are organization +level roles, which grant a user the specified permissions within a single Arthur organization. The second kind are +global roles, which grant the specified privileges across all organizations in the system. Global roles are intended for +administrators, so they can perform actions like managing organizations and roles at the global level. They should not +be used to grant non-admin users cross-organization access. Instead, users that need access to more than one +organization should have a distinct role for each organization. Commonly, the global administrator role only has +permissions to create new organizations and to manage custom roles for the platform. All model and data access should +be configured using organization scoped roles. See the {doc}`custom_rbac` for an overview of how to configure +custom roles for your Arthur installation. + +### Linking IdP Groups to Arthur Roles + +Roles are the link between the IdP's user groups and the Arthur access control system. As shown +in [Set Up an Identity Provider](#set-up-an-identity-provider), when you +configure an IdP, you will tell Arthur how to parse a user's groups out of the IdP response. The group, or list of +groups, returned from your IdP must match the names of custom roles configured in Arthur. For this reason, Arthur +enforces all custom roles to have unique names, so the platform can map a user group from an +external IdP to a specific set of permissions. This means **all roles in the system must have unique names, even across +organizations.** + +For example, if using OIDC and the IdP returns a JWT token of the following format, Arthur must be configured with roles +that match the groups listed under the "groups" field in the token. The group names are used to look up the roles that +apply for the user in Arthur. More examples of how to configure the OIDC JWT claim parsing can be found in +{doc}`setting_up_oidc_idp`. + +```json +{ + "sub": "1234567890", + "name": "John Doe", + "iat": 1516239022, + // this field in the token corresponds to the user's groups in the IdP + "groups": [ + // an "idp-admin" role must be created in Arthur to match this group + "idp-admin", + // an "org-1-user" role must be created in Arthur to match this group + "org-1-user" + ] +} +``` + +```{note} +It is ok if the OIDC token contains extra groups that are not matched to roles in Arthur. +It is not required that every group have a corresponding role, but at least one group must. +``` + +Similarly if using SAML, the SAML assertion from the IdP must contain some attribute values that contains the user's +groups in the IdP. More examples of how to configure the SAML attribute parsing can be found in +{doc}`Setting Up a SAML IdP `. + +```xml + + + + support@arthur.ai + + + John + + + Doe + + // this field in the assertion corresponds to the user's groups in the IdP + + // an "idp-admin" role must be created in Arthur to match this group + idp-admin + // an "org-1-user" role must be created in Arthur to match this group + org-1-user + + +``` + +```{note} +It is ok if the SAML assertion contains extra groups that are not matched to roles in Arthur. +It is not required that every group have a corresponding role, but at least one group must. +``` + +## Set Up an Identity Provider + +### {doc}`OIDC ` + +See {doc}`Setting Up an OIDC IdP ` for the steps to configure an OIDC IdP with Arthur. + +### {doc}`SAML ` + +See {doc}`Setting Up a SAML IdP ` for the steps to configure a SAML IdP with Arthur. + +## Creating Custom Roles + +As mentioned above, custom roles can be used to grant either permissions within an organization or permissions across +all organizations. This section will first cover how to create global roles, then it will cover how to create roles for +an organization. The steps outlined here are sufficient to get SSO working. For more details about managing custom RBAC +access control, please see the {doc}`custom_rbac` guide. + +(creating_global_roles_in_arthur_config)= + +### Creating Global Roles for Managing Organizations and RBAC Policies + +```{note} +In order to complete this section, you must have access to the Arthur Admin Console config page. +``` + +Global roles are intended to be used by a cluster administrator to manage organizations and roles in the Arthur +application. Global roles should be scoped with the minimal privileges and should be given out with caution. +**It is not recommended to grant model or data access with global roles as that would give access to every model in the +system.** Global roles can be created in the Arthur installer Admin Console configuration in the "Use a 3rd Party +Global Identity Provider" section where the IdP configuration YAML is set. A list of custom global roles can be provided +in the Identity Provider YAML under the `globalRoleDefs` key. The following +example shows a global role for an Arthur cluster admin to manage organizations and RBAC for the +installation: + +```yaml + globalRoleDefs: + # Here we specify a list to define multiple global roles + - name: "idp-admin" # change the name of this role to match the cluster administrator group name in your IdP + # this role grants a user permissions to manage organizations and RBAC policies in Arthur + permissions: + custom_roles: + - read + - write + - delete + organization_global: + - read + - write + organization: + - read + - delete +``` + +Once you add a role to your config, be sure to click "Save" at the bottom of the page and then deploy the change. After +the update completes, the new global role should be created. + +(creating_organization_roles)= + +### Creating Organization Scoped Roles for Non-admin Users + +Completing this section will require either access to the Arthur superadmin user, or access to a previously created, +custom global role assumable via an IdP +(see [above](#creating-global-roles-for-managing-organizations-and-rbac-policies)). +Additionally, only installations with SSO configured can use custom RBAC policies. If you do not have SSO configured, +please see {doc}`../standard_access_control`. + +The section below assumes an organization already exists that you would like to give users access to. If you would like +to create a new Arthur organization, please check out the +{ref}`Managing RBAC and Organizations for SSO users `, +then come back here to add roles to that new organization. + +Using either the Arthur superadmin user or having assumed a custom RBAC role with global scope to manage RBAC, +organization scoped roles can be created using the Arthur API. The following is an example of a request to create a new +role in an organization. Be sure to fill in the missing values for the hostname, +authorization token (must be a superadmin or your token from a custom global role), organization ID, and change the role +names to match your IdP user groups. See +{ref}`Managing RBAC and Organizations for SSO users ` for an overview of role +permissions and some example roles. + +```shell +curl --location 'https:///api/v3/authorization/custom_roles' \ +--header 'Arthur-Organization-ID: ' \ +--header 'Content-Type: application/json' \ +--header 'Authorization: Bearer ' \ +--data '{ + "roles": [ + { + "role_name": "my-idp-group-1", + "inherited_role_names": [ + "Administrator" + ] + }, + { + "role_name": "my-idp-group-2", + "inherited_role_names": [ + "Model Owner" + ] + } + ] +}' +``` + +This sample API call will create two custom roles in the `` organization. These +roles will apply to users in the "my-idp-group-1" or "my-idp-group-2" groups managed by the IdP. + +### Granting Users Access to Multiple Organizations + +Users can be given access to multiple organizations by creating a unique custom role in each organization, then adding +them to the associated groups in the IdP. For example, if you have two organizations, `org-1` and `org-2`, the Arthur +cluster administrator will need to create a custom role in each organization. Let's call them `role-1` and `role-2` +respectively. As described above, these role names will need to correspond to user groups in the IdP so please name them +according to your group names. With two organizations and a role created in each, the last step is to add your users to +both groups in your IdP, and they will be able to access both organizations. + +```{note} +If users have access to more than one organization, they will need to specify one to use during API calls. +See the next section for more information on how to specify an organization when using the Arthur API. +``` + +## API Authentication with Multiple Organization Users + +The Arthur platform separates resources logically by Arthur {ref}`Organizations `. When an Arthur +deployment is configured with Arthur's Standard Authentication mechanism, user access is granted to one organization at +a time, so all interactions with the platform are automatically scoped with that organization. + +However, when SSO is enabled, SSO tokens can grant access to one or more Arthur organizations at a time. They do this by +listing multiple roles for a user within the token, each with access to a distinct organization. As a result, users can +have access to more than one organization at a time, and Arthur cannot determine which organization the user intends to +take an action in. Therefore, when SSO users have access to more than one organization, they must select a specific +Arthur Organization in each request to the platform via the methods described in this section. + +### Alternatives for Selecting an Organization in the Arthur API + +1. Request Header +2. Session-Based Organization Tracking +3. Arthur SDK Client +4. Deep Linking to an Organization in the UI + +### Request Header + +In an API call made by an SSO-authenticated user with access to more than one organization, the platform will first +check for a request header with an `Arthur-Organization-ID` key. If one is found, the platform will parse it and, +assuming the organization exists and the calling user can access it, continue the request with the specified ID as its +target organization. If the header is not found, it will fall back to one of the other methods described below. +If the header is present and the user does not have access to the organization, the API will return a 404 status code. + +### Session-Based Organization Tracking + +If no organization-specifying request header is included in the request, the platform will then use session information +to determine one. + +Sessions enable users to establish a long-lived association with an organization that can be used to automatically scope +all requests to a specific organization. Users can establish a session using the +[PUT /organizations/current](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/organizations/paths/~1organizations~1current/put) +endpoint. Similarly, they can retrieve the organization from their current session with the +[GET /organizations/current](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/organizations/paths/~1organizations~1current/get) +endpoint. + +By calling `PUT /organizations/current` with a target organization specified, a user receives an `_arthur_session` +cookie that associates future requests with the target organization. Any future calls to `PUT /organizations/current` +will return a new `_arthur_session` cookie to track your new session for whichever organization is specified in +the `PUT` call. + +By calling `GET /organizations/current` with an `_arthur_session` cookie included in the request, users can retrieve the +organization their current session is associated with. + +```{note} +Sessions do not provide any access to Arthur on their own. They only keep track of the user's association with a +specific organization. Users must also have an access token to authenticate with the Arthur APIs. +Since sessions do not grant any access to the Arthur platform, they expire after 30 days to prevent +users from repeatedly having to specify an organization. +``` + +### Arthur SDK Client + +For SSO-authenticated users with access to more than one organization working with the Arthur SDK, the SDK client allows +selecting a specific organization. _Note: SDK users with access to a single Arthur organization will automatically have +their one organization set._ + +When an SDK user is instantiating the +[`ArthurAI` client](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.client.client.ArthurAI.html#arthurai.client.client.ArthurAI) +, they can first specify which organization they want that client to be associated with by passing in that +organization's ID as the `organization_id` optional parameter. + +```python +connection = ArthurAI(organization_id=org_id: str, ...) +``` + +After the `ArthurAI` client has been instantiated, users can update the client's current organization by calling +the [`set_current_org()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.client.client.ArthurAI.html#arthurai.client.client.ArthurAI.set_current_org) +method. + +```python +connection.set_current_org(org_id: str) +``` + +At any point, SDK users can access their `ArthurAI` client's current organization by calling +the [`get_current_org()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.client.client.ArthurAI.html#arthurai.client.client.ArthurAI.get_current_org) +method. + +```python +current_org = connection.get_current_org() +``` + +### Deep Linking to an Organization in the UI + +If an SSO-authenticated user has access to more than one organization, Arthur allows them to bypass manual organization +selection through deep linking. A user can append the url parameter `?organization_id=` to the Arthur +platform host name, where `` is equal to one of the organization IDs to which the user has access. This +will tie the users session to that organization ID upon authentication through SSO. + +N.B. This will only work when appended to the platform host name. +E.g. `https://[Arthur hostname]/?organization_id=` This will not work if you are attempting to apply the +parameter to any other path on the Arthur host. E.g. `https://[Arthur hostname]/login/?organization_id=` will +NOT work. + +```{toctree} +:maxdepth: 2 +:hidden: + +OIDC +SAML +Custom RBAC +``` + diff --git a/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/setting_up_oidc_idp.md.txt b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/setting_up_oidc_idp.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ce66d8fbfb895538bcd97feaa5918027099f7e2d --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control-overview/sso-access-control/setting_up_oidc_idp.md.txt @@ -0,0 +1,555 @@ +# Setting Up an OIDC IdP + +```{note} +SSO configurations are only supported in on-prem Arthur installations. +``` + +This page provides a walk-through for how to configure your Arthur installation to work with an OIDC compatible IdP. +In order to complete this guide, you need +administrator access to your IdP and access to your Arthur installation's admin console configuration. Additionally, you +will either need access to the Arthur superadmin user or be able to assume a role in your IdP to give yourself RBAC +management permissions in Arthur. + +This guide will walk through the following steps: + +1. Configure the IdP user groups and OIDC token claims +2. Configure the IdP OIDC Settings +3. Configure Arthur to work with your IdP +4. Apply the Arthur IdP YAML configuration +5. Create organization user roles to match the IdP user groups +6. Test Access +7. Cleaning Up + +## 1. Configure the IdP user groups and OIDC token claims + +In order to properly map users to permissions, Arthur requires a claim in your OIDC JSON Web Token (JWT) that contains +information about the group memberships of the user. Each group in the IdP should correspond to a role in Arthur's +{doc}`custom_rbac` permission system. + +This process can vary depending on your IdP, but most IdP's should have a user grouping mechanism, and a mechanism to +configure attributes in the JWT claims. For example using Okta, admins can +configure the JWT claims to include group information under their account's Security -> API -> default -> Claims then +the "Add Claim" button. From the popup, give the claim a name, "Groups" in this example, set the "Include in token type" +to "Access Token", select "Value type" as "Groups", and include a "Matches regex" filter to select the groups to +include: + +![okta-oidc-groups-claims](/_static/images/sso/okta-configure-oidc-groups-claims.png "Okta OIDC Groups Claims") + +Retrieving an example OIDC token is IdP-specific and may involve completing the sign-in flow via a script or API client. +An alternative can be to use a 3rd party like [https://oidcdebugger.com](https://oidcdebugger.com), but that will +require +whitelisting `https://oidcdebugger.com/debug` as a valid redirect URL for your Arthur SSO app (this could be enabled +temporarily for debugging, then removed). Here is an example JWT after setting the group claims field: + +```json +{ + "iss": "https://dev.okta.com/oauth2/default", + "aud": "api://default", + "scp": [ + "openid" + ], + "Groups": [ + "idp-admin", + "org-1-model-owner", + "org-2-model-owner" + ], + "FirstName": "John", + "LastName": "Doe", + "Login": "john.doe@arthur.ai" +} +``` + +As the example token shows, the user's groups in the IdP are populated as a string list in the "Groups" field in the +token. Arthur will use this list of groups to match the user to the corresponding roles in Arthur by name. + +## 2. Configure the IdP OIDC Settings + +In order for your IdP to speak to Arthur, it needs to know where to find it. Enter the following URL in your IdP's +configuration to whitelist Arthur's callback endpoint (sign-in redirect +URL): `https:///login/callback`. + +Additionally, the IdP will need to know what OIDC protocol to speak with Arthur. Today, Arthur supports two protocol +flows: + +1. `implicit` +2. `PKCE` + +Both flows are intended to be used with "Single Page Applications" or SPAs. Follow the configuration for your IdP that +matches one of those two flows with SPAs. Additionally, note the following settings from your IdP in order to use in +the Arthur configuration below: + +- Client ID +- Resource ID (if available) +- OIDC flow (PKCE or implicit) +- Audience (value that is set in the token by the IdP) + +## 3. Configure Arthur to work with your IdP + +Next, Arthur needs to know how to handshake with your IdP. To do that, Arthur requires the following +information: + +1. Your IdP's discovery URL, typically in the format `/.well-known/openid-configuration` URL that contains the + relevant endpoints for your IdP. + ```{note} + If this page isn't accessible to Arthur due to CORS or other restrictions, the values can be provided manually. + ``` +2. One or more IdP administrator user groups that will be paired to global custom roles in Arthur + (see [here](#configure-the-arthur-global-roles) for a description of what these are for) +3. An understanding of your OIDC token claims (values) and how to parse user information out of it +4. The four configuration values captured above from your IdP + +With that information available, it is possible to fill out Arthur's IdP configuration YAML. The next subsections +explain each subsection of the Arthur YAML configuration, and is followed by some complete examples further down. + +### Configuring the IdPs discovery URL + +Almost all OIDC IdP's have accessible discovery URLs, but some do not provide CORS support for them, so their contents +need to be filled out manually. To support either option, Arthur has two configurations that can be +used, `discoveryBaseURL` or `endpointOverrides`. If your IdP has CORS restrictions, +see [Appendix B](#appendix-b-setup-for-idps-with-cors-restrictions) for additional +setup that is required. + +```yaml +# use this option if your IdP has an accessible discovery URL +# IMPORTANT: don't include the /.well-known/openid-configuration suffix!! +# for example, if the full URL is https:///oauth2/default/.well-known/openid-configuration +# only specify: https:///oauth2/default +discoveryBaseURL: "https:///oauth2/default" +# use this option if your IdP has CORS restrictions on the discovery URL, otherwise comment this out. +# fill in the values manually from the discovery endpoint's contents +endpointOverrides: + issuer: "issuer string for the IDP" + authorization_endpoint: "URL ending in /authorize" + token_endpoint: "URL ending in /token" + jwks_uri: "URL ending in /keys" + userinfo_endpoint: "URL ending in /userinfo" + # note not all IdPs will have the following endpoints, fill in as many as you can + end_session_endpoint: "URL ending in /logout" + device_authorization_endpoint: "URL ending in /devicecode" + revocation_endpoint: "URL ending in /revoke" + introspection_endpoint: "URL ending in /introspect" + registration_endpoint: "URL ending in /clients" +``` + +### Configure the Arthur Global Roles + +Arthur has the ability to create roles for the cluster administrators during the configuration of the IdP. These roles +are often needed by admins to configure RBAC and create organizations for other users in the system. See +{ref}`creating_global_roles_in_arthur_config` for a deep dive on how to use global roles. + +This section of the YAML config is under the `globalRoleDefs` field. It accepts a list of role definitions that will be +created when the configuration is applied. The names of the roles in this section must match the user groups in your IdP +in order to be able to assume them in Arthur. + +```yaml + globalRoleDefs: + # Here we can specify a list to define multiple global roles + - name: "idp-admin" # change this name to match the cluster administrator group name in your IdP + permissions: + custom_roles: + - read + - write + - delete + organization_global: + - read + - write + organization: + - read + - delete + model: + - read + - write + - delete +``` + +### Parsing the IdP JWT claims + +In order for Arthur to communicate with your IdP, it needs to understand the format of the JWT claims your IdP uses. +This section of the config falls under the `accessTokenValidation` YAML field. This section is designed to be flexible +to +support a variety of claim formats, so it has a lot of options. At its core, the goal is to tell Arthur how to be +able to extract the following information from the claims: + +- user roles/groups +- first name +- last name +- email +- user ID + +Each field has a corresponding YAML configuration that defines where to find the information in the JWT claims. For +example: + +```yaml +claimMapping: + firstName: FirstName +``` + +This configuration tells Arthur that it can find the user's first name under the "FirstName" claim in the +JWT. Such a token might look like this: + +```json +{ + "iss": "https://dev.okta.com/oauth2/default", + "aud": "api://default", + "scp": [ + "openid" + ], + "Groups": [ + "idp-admin", + "org-1-model-owner", + "org-2-model-owner" + ], + "FirstName": "John", + "LastName": "Doe", + "Login": "john.doe@arthur.ai" +} +``` + +More examples of how to parse user information out of the JWT claims can be +found [below](#appendix-a-more-examples-of-jwt-claims-and-how-to-parse-them). + +### Full Configuration Examples + +Here is an example of a full configuration, combining each section described above. + +```yaml +version: v2 +kind: OIDC +config: + # discovery URL without the /.well-known/openid-configuration suffix + discoveryBaseURL: https://example.com/oauth2/default + # Either "implicit" or "PKCE" + flowType: PKCE + # client ID from your IdP for the Arthur SSO application + clientID: "client id string" + # optional: resource ID from your IdP for the Arthur SSO application if required by the IdP + resourceID: "" + authorizeScopes: + - openid # required for OIDC + # use this section to define global roles + # one example role would be to give the cluster admin permissions to create organizations and manage custom roles + globalRoleDefs: + - name: "iam-admin" # change this to match the user group name in your IdP for administrators + permissions: + custom_roles: + - read + - write + - delete + organization_global: + - read + - write + organization: + - read + - delete + # this section describes how to parse the user information out of the JWT returned from the IdP + # this is used by Arthur to understand who the user is and what their roles are + accessTokenValidation: + type: JWT # only JWT is supported today + # fields in the token Arthur will use to extract the authentication information + claimMapping: + roles: Groups # this is telling Arthur to look in the "Groups" claim to find the list of user's roles + userID: EmployeeID + username: Login + firstName: FirstName + lastName: LastName + email: Login + + # one or more audiences to validate, this should match your IdP's configuration + audience: + - api://default + + # optional override signature algo + # signatureAlgo: RS256 + +``` + +Here is an additional descriptions of the fields that need to be set in the config YAML above: + +* `discoveryBaseURL`: This is the base URL for your Identity Provider. Your IdP should have + a `/.well-known/openid-configuration` endpoint and the + discoveryBaseURL is simply that url minus the `/.well-known/openid-configuration` part. +* `flowType`: We support both implicit and PKCE flows. Consult with your team to decide which OIDC flow type is right + for your organization. +* `clientID`: When you create the application integration in your IdP, a Client ID will be provided to you. Paste that + value into this field. +* `resourceID`: This is optional. If your IdP gives you a Resource ID when creating your application integration, paste + the value here. +* `claimMapping`: We extract various pieces of authentication information from the provided JWT access token. However, + there is no common standard for + how these pieces of information should be formatted in the token. For us to extract this information from the token, + we need you to explicitly tell Arthur + where this information is stored in the token. For example, a username could be stored in a field called `username` + or `login` or `email` or `userID`. + In order to get this user information, a mapping needs to be provided for the following items + * `roles`: This is the field for where either a single authorization role or a list of authorization roles will be + specified. + Note that this is **not** where you paste a list of roles, this is **the name of a field** in the JWT where the + user's roles are specified. + For help with role definitions, see {doc}`custom_rbac`.(Required) + * `userID`: This is the field for a unique identifier for the user; this is frequently the same as `username` + and/or `email`. (Optional, omit if empty) + * `username`: This is the field for the user's unique username; this is frequently the same as `username` + and/or `email`. (Optional, omit if empty) + * `firstName`: This is the field for the user's first name. (Optional, omit if empty) + * `lastName`: This is the field for the user's last name. (Optional, omit if empty) + * `email`: This is the field for the user's email. (Optional, omit if empty) +* `audience`: This is part of the JWT standard. The `aud` field for any JWT you create must be a value in this list. For + example in the above configuration, any token that has an `aud` field that is not set to `api://defaults`, the token + will be automatically rejected by Arthur. If you are having trouble finding this value, it is frequently the same as + your `resourceID`. Remember to format this as a _list_, not a single value. + +```{note} +If your IdP has CORS restrictions see +[Appendix B](#appendix-b-setup-for-idps-with-cors-restrictions) below for a workaround. +``` + +## 4. Apply the Arthur IdP YAML configuration + +Once you have your YAML configuration file ready, you need to add it to your Arthur installation. With the Arthur admin +console open, navigate to the "Use a 3rd Party Global Identity Provider" section and select "OIDC". This will expose a +text box for you to paste the YAML config file assembled above. When pasting, make sure whitespace is preserved and the +YAML document has consistent spacing (do not mix tabs and spaces). Here is a screenshot of the config section: + +![arthur-oidc-config-page](/_static/images/sso/arthur-oidc-config-page.png "Arthur OIDC Configuration Page") + +Once you have added your config files, scroll to the bottom and click "Save" to save the config. Then go to the latest +version and click "Deploy" to roll out the change to the cluster. + +## 5. Create organization user roles to match the IdP user groups + +In order to complete this section, you will need access to the Arthur superadmin user credentials set during your +install, or you will need to be able to assume the role defined in the Arthur IdP config YAML created above in +the `globalRoleDefs` section. + +In order to use the API example linked below, you will need a Bearer token (authentication token) to include with your +API request. There are a few options available to retrieve a token: + +1. **Retrieve a global role token directly from your IdP** - Most IdPs will have a method to retrieve tokens for users. + Some companies make scripts or APIs that allow retrieving a token. If your IdP does not have an automated method to + retrieve a token, you can try setting up a tool like [https://oidcdebugger.com](https://oidcdebugger.com) (this may + involve adding `https://oidcdebugger.com` as an allowed URL in your IdP settings). +2. **Retrieve a global role token from your browser cookies** - If you sign in to Arthur as a user with a global role, + the UI will not be fully functional, but it will have a valid access token in the cookies. If you navigate to your + browser's developer console and then go to the Application Storage/Cookies section, you should see a cookie like + `ArthurAuth0`, which is your authentication token. Note: if your user has a large number of groups, there may be + multiple cookies of the form `ArthurAuthN`. In this case your token was too large to fit in the browser cookie, so + it had to be split. You can assemble the full token by concatenating the values of the `ArthurAuthN` cookies in + order. +3. Use the [/login](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/auth/paths/~1login/post) API endpoint + with the superadmin user's credentials set during the Arthur install (only available on-prem). + +Using either of those credentials, we can use the Arthur API to define roles in Arthur that match the user group names +in your IdP. See the {ref}`creating_organization_roles` section for an example API request to create custom roles in +Arthur. Importantly, the role +names must uniquely match to a user group in your IdP in order for your users to be able to assume those permissions in +Arthur. Therefore, the roles in Arthur must be globally unique in the entire Arthur installation. + +## 6. Test Access + +At this point everything should be configured correctly to sign in to Arthur via SSO. Either navigate to your IdP +or the Arthur homepage to test logging in. + +## 7. Cleaning Up + +Once users are successfully able to log in to Arthur via the IdP, you should do the following to ensure proper security +best-practices remain enforced: + +- Restrict any Arthur global roles to only allow access to essential admin functions +- Set the Arthur superadmin user password securely, and either store the password in a vault, or discard the password + entirely. superadmin shouldn't be used going forward. +- Set up a policy to routinely rotate the superadmin password to keep it secure + +Together, these practices will help ensure the security of your Arthur installation, and will give your IdP sole control +over the platform and who is able to access it. + +## Common Troubleshooting + +If after following the steps above, users are not able to log in via the IdP try some of these common troubleshooting +tips: + +### Does the user properly redirected to the IdP's log in screen? + +If not, there is likely a configuration error in the Arthur YAML config with the IdP discovery URL. Double check +that the url entered resolved correctly when you append `/.well-known/openid-configuration` to the end of it. The full +URL should be viewable in your browser or via a REST client. + +### Once the user authenticates with the IdP, are they redirected to the Arthur homepage? + +If not, there is likely a configuration error with the IdP and the URLs that it uses to communicate with Arthur. +Double-check the redirect (whitelisted) URL is configured correctly for the Arthur installation +at `https:///login/callback`. + +### A user can see the Arthur home page, but can't see any of the model in their organization + +If a user cannot see any of the models in their organization, it means they either don't have the necessary permissions +to access models (see {doc}`../../reference/permissions_by_endpoint`) or they were not able to correctly assume the role +in Arthur. Double-check the groups in +their JWT claims match the role names that have been configured in Arthur. A superadmin or global role user with +permissions to manage RBAC can see a list of roles in the installation by using the following API call. Be sure to +replace the HOST and AUTH TOKEN for your installation and user: + +```shell +curl --location 'https:///api/v3/authorization/custom_roles' \ +--header 'Authorization: Bearer ' +``` + +## Appendix A: More examples of JWT claims and how to parse them + +This section outlines some additional ways to use the `accessTokenValidation` section of the Arthur IdP config YAML +format. The below examples include sample JWTs, then corresponding YAML for how to parse them. + +### Basic Full Example + +This example shows how to parse a user's information from JWT claims in a typical format. +Example parsed JWT claims JSON: + +```json +{ + "iss": "https://dev.okta.com/oauth2/default", + "aud": "api://default", + "scp": [ + "openid" + ], + "Groups": [ + "idp-admin", + "org-1-model-owner", + "org-2-model-owner" + ], + "FirstName": "John", + "LastName": "Doe", + "Login": "john.doe@arthur.ai", + "EmployeeID": "1234567890" +} +``` + +Corresponding settings for the Arthur IdP config YAML `accessTokenValidation` for the user information field: + +```yaml +accessTokenValidation: + type: JWT + claimMapping: + roles: Groups + userID: EmployeeID + username: Login + firstName: FirstName + lastName: LastName + email: Login +``` + +### Minimal Example + +This example shows how to parse a user's information from JWT claims when many fields are missing. +Example parsed JWT claims JSON: + +```json +{ + "iss": "https://dev.okta.com/oauth2/default", + "aud": "api://default", + "scp": [ + "openid" + ], + "Groups": [ + "idp-admin", + "org-1-model-owner", + "org-2-model-owner" + ], + "user": "john.doe@arthur.ai" +} +``` + +Corresponding settings for the Arthur IdP config YAML `accessTokenValidation` for the user information field: + +```yaml +accessTokenValidation: + type: JWT + claimMapping: + roles: Groups + userID: user + username: user + firstName: "" + lastName: "" + email: user +``` + +## Appendix B: Setup for IdPs with CORS Restrictions + +Completing this will require access to the Kubernetes cluster Arthur is running in, and the ability to create ingress +resources in that cluster. + +If your OIDC Identity Provider does not support CORS (common with Microsoft Azure AD), you will need to proxy +requests via the Arthur backend. The following examples show how this can be done with a cluster using the +NGINX ingress controller. + +This first example YAML configures a route on NGINX that will proxy OIDC connections to your IdP. You'll need to +replace the `` and `` placeholders, then apply it to your cluster with +`kubectl apply -n -f file.yaml`. There should be two places to fill in each variable below. + +```yaml +apiVersion: v1 +kind: Service +metadata: + name: external-idp +spec: + type: ExternalName + externalName: "" +--- +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: external-idp + annotations: + kubernetes.io/ingress.class: nginx + nginx.ingress.kubernetes.io/rewrite-target: /$2 + nginx.ingress.kubernetes.io/backend-protocol: "HTTPS" #important + nginx.ingress.kubernetes.io/upstream-vhost: "" +spec: + rules: + - host: "" + http: + paths: + - backend: + service: + name: external-idp + port: + number: 443 + path: /oidc(/|$)(.*) + pathType: Prefix + tls: + - hosts: + - "" + secretName: kotsadm-tls +``` + +After you've applied the above configuration to your cluster, you should be able to visit your IdP's +`/.well-known/openid-configuration` endpoint at the following URL: +`https:///oidc/`. Once that is accessible, we need to modify +the OIDC YAML configuration file. Fill in the following example +with the correct values in the `endpointOverrides` section. Note, the `issuer` and `authorization_endpoint` fields +should match what is in your IdP's `/.well-known` spec. The rest of the values should use the same path as shown in the +IdP's `/.well-known` spec, but with the value of `/oidc/` substituted for the host of the IdP. +The following example shows a proper CORS config for an IdP at the `https://XXXX.okta.com` address. + +```yaml +version: v2 +kind: OIDC +config: + discoveryBaseURL: https://XXXX.okta.com/oauth2/default + # if your IdP has CORS restrictions with the metadata URL, + # specify this block to prevent using the metadata endpoint to look them up + endpointOverrides: + # these first two match the IdP's .well-known spec + issuer: "https://XXXX.okta.com/oauth2/default" + authorization_endpoint: "https://XXXX.okta.com/oauth2/default/authorize" + # notice the following are all modified to add the /oidc prefix in the URL + token_endpoint: "https:// Configure SAML -> Group +Attribute Statements, then specifying a name for the attribute and a filter for the groups to include: + +![okta-saml-groups-attribute](/_static/images/sso/okta-configure-saml-groups-assertion.png "Okta SAML Assertion Groups Attribute") + +Setting this configuration produces the following attribute in the SAML assertion (in Okta click "Preview the SAML +Assertion" button to see a sample): + +```xml + + + + Everyone + admins + org-1-model-owners + + + +``` + +## 2. Configure the Arthur service provider URLs in the IdP + +In order for your IdP to speak to Arthur, it needs to know where to find it. Enter the following URLs in your IdP's +configuration to Arthur's SAML endpoints: + +- ACS URL (SSO URL): `https:///api/v3/saml/sso` +- Entity ID: `https:///api/v3/saml/sso` +- Start URL: `https:///` + +```{note} +If your IdP will be sending signed assertions to Arthur, you will also need to generate and upload the public key +(certificate) Arthur will be using in your IdP. This will be the same certificate you set in the Arthur configuration +[below](#apply-the-arthur-idp-yaml-configuration). Please follow your own company policies to obtain a certificate +for Arthur. If you have no internal guidelines, then use a tool like +[ssh-keygen](https://www.ibm.com/docs/en/spectrum-control/5.3.7?topic=agents-creating-certificate-ssh-protocol) to +generate them +``` + +## 3. Configure Arthur to work with your IdP + +Additionally, Arthur needs to know how to handshake with your IdP. To do that, Arthur requires the following +information: + +1. Your IdP's metadata URL or the metadata XML payload (some IdPs require it be downloaded, either is fine) +2. One or more IdP administrator user groups that will be paired to global custom roles in Arthur + (see [here](#configure-the-arthur-global-roles) for a description of what these are for) +3. An understanding of your SAML assertion and how to parse user information out of it + +With those three things available, it is possible to fill out Arthur's IdP configuration YAML. The next subsections +explain each section of the Arthur YAML configuration, and are followed by some complete examples further down. + +### Configuring the IdPs metadata URL + +Some IdP's host their metadata XML at a public URL, while others only have it available for download privately. To +support either option, Arthur has two configurations that can be used: + +```yaml +# use this option if your IdP has a public URL for its metadata +metadataURL: "link to IdP metadata goes here" +# use this option if your IdP does not have a public URL and include the XML payload +# make sure to indent the XML payload two spaces and make sure the X509Certificate lines +# do not have more than two leading whitespaces! +metadataXML: | + + + ... + CERTIFICATE LINE 1 + CERT LINE 2 + CERT LINE 3 + CERT LINE 4 + LAST CERT LINE + + +``` + +```{warning} +If using the `metadataXML` configuration option, make sure to indent the entire XML payload two spaces. YAML expects +multi-line values to be indented under the key `metadataXML`. +``` + +```{warning} +Additionally, the assertion's `X509Certificate` XML attribute is a multi-line value within the XML. +Any new lines in the certificate value need to be indented only two spaces (all the way to the left of the YAML value). +Otherwise, the extra whitespaces introduces characters which will invalidate the certificate value. +``` + +### Configure the Arthur Global Roles + +Arthur has the ability to create roles for the cluster administrators during the configuration of the IdP. These roles +are often needed by admins to configure RBAC and create organizations for other users in the system. See +{ref}`creating_global_roles_in_arthur_config` for a deep dive on how to use global roles. + +This section of the YAML config is under the `globalRoleDefs` field. It accepts a list of role definitions that will be +created when the configuration is applied. The names of the roles in this section must match the user groups in your IdP +in order to be able to assume them in Arthur. + +```yaml + globalRoleDefs: + # Here we can specify a list to define multiple global roles + - name: "idp-admin" # change this name to match the cluster administrator group name in your IdP + permissions: + custom_roles: + - read + - write + - delete + organization_global: + - read + - write + organization: + - read + - delete + model: + - read + - write + - delete +``` + +### Parsing the IdP SAML Assertion + +In order for Arthur to communicate with your IdP, it needs to understand the format of the SAML assertion your IdP uses. +This section of the config falls under the `assertionAttributes` YAML field. This section is designed to be flexible to +support a variety of assertion formats, so it has a lot of options. At its core, the goal is to tell Arthur how to be +able to extract the following information from the assertion: + +- user roles/groups +- first name +- last name +- email +- user ID + +Each field has a corresponding YAML field the defines where to find the information in the SAML assertion XML. For +example: + +```yaml +firstNameAttribute: + name: "employeeFirstName" +``` + +This configuration tells Arthur that it can find the user's first name under the "employeeFirstName" attribute in the +XML assertion. Such an assertion might look like this: + +```xml + + + + Ian + + +``` + +More examples of how to parse attributes out of the SAML assertion can be +found [below](#appendix-a-more-examples-of-saml-assertion-values-and-how-to-parse-them). + +### Full Configuration Examples + +Here is an example of a full configuration, combining each section described above. + +```yaml +version: v1 +kind: SAML +config: + # if your IdP hosts its metadata, provide the URL to it here + metadataURL: "link to IdP metadata goes here" + # if the IdP does not host the metadata, provide the XML payload here and comment out metadataURL + # metadataXML: | + # + # + # ... + # + # + + # this section describes how Arthur will parse the SAML assertion from your IdP + # for each required attribute, Arthur will use the "name" field to match to an XML attribute in the SAML assertion + assertionAttributes: + # this roleAttribute configuration will use a "groups" attribute in the XML assertion which expects the + # roles in separate XML AttributeValues within the assertion Attribute + roleAttribute: + name: "groups" + useAllAttributeValues: True + firstNameAttribute: + name: "employeeFirstName" + lastNameAttribute: + name: "employeeLastName" + emailAttribute: + name: "company_email" + userIdAttribute: + name: "companyUserID" + globalRoleDefs: + # Here we specify a global role for the IdP user group "idp-admin" to create and manage RBAC in Arthur + - name: "idp-admin" + permissions: + custom_roles: + - read + - write + - delete + organization_global: + - read + - write + organization: + - read + - delete + model: + - read + - write + - delete + +``` + +## 4. Apply the Arthur IdP YAML configuration + +Once you have your YAML configuration file ready, you need to add it to your Arthur installation. With the Arthur admin +console open, navigate to the "Use a 3rd Party Global Identity Provider" section and select "SAML". This will expose a +text box for you to paste the YAML config file assembled above. When pasting, make sure whitespace is preserved and the +YAML document has consistent spacing (do not mix tabs and spaces). Here is a screenshot of the config section: + +![arthur-saml-config-page](/_static/images/sso/arthur-saml-config-page.png "Arthur SAML Configuration Page") + +```{note} +If your IdP enforces signed authorization requests, this config page also provides the ability to upload a +certificate and private key for Arthur to use when making the requests. Click the "Upload a file" button for the Public +Certificate and Private Key sections of the config to upload the appropriate files for your IdP. +``` + +Once you have added your config files, scroll to the bottom and click "Save" to save the config. Then go to the latest +version and click "Deploy" to roll out the change to the cluster. + +## 5. Create organization user roles to match the IdP user groups + +In order to complete this section, you will need access to the Arthur superadmin user credentials set during your +install, or you will need to be able to assume the role defined in the Arthur IdP config YAML created above in +the `globalRoleDefs` section. + +In order to use the API example linked below, you will need a Bearer token (authentication token) to include with your +API request. There are a few options available to retrieve a token: + +1. **Retrieve a SAML assertion from your IdP and exchange with Arthur** - Most IdPs will have a method to retrieve a + SAML assertion for users. Some companies make scripts or APIs to do so. If your IdP does not have an automated method + to retrieve an assertion, use one of the other options below. Once you have an assertion, you can exchange it for an + Arthur access token with the follow API call to Arthur: + ```shell + curl --location --request POST 'https:///api/v3/saml/sso' \ + --header 'Content-Type: application/x-www-form-urlencoded' \ + --data-urlencode 'SAMLResponse=' + ``` +2. **Retrieve a global role token from your browser cookies** - If you sign in to Arthur as a user with a global role, + the UI will not be fully functional, but it will have a valid access token in the cookies. If you navigate to your + browser's developer console and then go to the Application Storage/Cookies section, you should see a cookie like + `Authentication`. The authentication token is the value of that cookie. +3. Use the [/login](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/auth/paths/~1login/post) API endpoint + with the superadmin user's credentials set during the Arthur install (only available on-prem). + +Using either of those credentials, we can use the Arthur API to define roles in Arthur that match the user group names +in your IdP. See the {ref}`creating_organization_roles` section for an example API request to create custom roles in +Arthur. Importantly, the role +names must uniquely match to a user group in your IdP in order for your users to be able to assume those permissions in +Arthur. Therefore, the roles in Arthur must be globally unique in the entire Arthur installation. + +## 6. Test Access + +At this point everything should be configured correctly to sign in to Arthur via SSO. Either navigate to your IdP +or the Arthur homepage to test logging in. + +## 7. Cleaning Up + +Once users are successfully able to log in to Arthur via the IdP, you should do the following to ensure proper security +best-practices remain enforced: + +- Restrict any Arthur global roles to only allow access to essential admin functions +- Set the Arthur superadmin user password securely, and either store the password in a vault, or discard the password + entirely. superadmin shouldn't be used going forward. +- Set up a policy to routinely rotate the superadmin password to keep it secure + +Together, these practices will help ensure the security of your Arthur installation, and will give your IdP sole control +over the platform and who is able to access it. + +## Common Troubleshooting + +If after following the steps above, users are not able to log in via the IdP try some of these common troubleshooting +tips: + +### Does the user properly redirected to the IdP's log in screen? + +If not, there is likely a configuration error in the Arthur YAML config with the IdP metadata or the URL to access it. +Another problem could be if your IdP expects Arthur to make signed requests to authenticate users. If that is the case, +be sure you have correctly configured Arthur's certificate and private key as +described [above](#apply-the-arthur-idp-yaml-configuration). + +### Once the user authenticates with the IdP, are they redirected to the Arthur homepage? + +If not, there is likely a configuration error with the IdP and the URLs that it uses to communicate with Arthur. +Double-check the ACS (SSO) URL is configured correctly for the Arthur installation +at `https:///api/v3/saml/sso`. + +### A user can see the Arthur home page, but can't see any of the model in their organization + +If a user cannot see any of the models in their organization, it means they either don't have the necessary permissions +to access models (see {doc}`../../reference/permissions_by_endpoint`) or they were not able to correctly assume the role +in Arthur. Double-check the groups in +their SAML assertion match the role names that have been configured in Arthur. A superadmin or global role user with +permissions to manage RBAC can see a list of roles in the installation by using the following API call. Be sure to +replace the HOST and AUTH TOKEN for your installation and user: + +```shell +curl --location 'https:///api/v3/authorization/custom_roles' \ +--header 'Authorization: Bearer ' +``` + +## Appendix A: More examples of SAML assertion values and how to parse them + +This section outlines some additional ways to use the `assertionAttributes` section of the Arthur IdP config YAML +format. The below examples include sample SAML assertions, then corresponding YAML for how to parse them. + +### Basic Full Example + +This example shows how to parse a user's information from a SAML assertion when each field is its own Attribute and the +user's groups are each in their own AttributeValue. +Example SAML assertion XML: + +```xml + + + + John + + + Doe + + + john.doe@arthur.ai + + + 1234567890 + + + group1 + group2 + group3 + + + +``` + +Corresponding settings for the Arthur IdP config YAML `assertionAttributes` for the user information field: + +```yaml + assertionAttributes: + roleAttribute: + name: "userGroups" + useAllAttributeValues: True + firstNameAttribute: + name: "employeeFirstName" + lastNameAttribute: + name: "employeeLastName" + emailAttribute: + name: "employeeEmail" + userIdAttribute: + name: "employeeID" +``` + +### Parsing User Groups from Multiple Attribute Values + +This example shows how to parse a user's groups from a SAML assertion when each group is its own AttributeValue. +Example SAML assertion XML: + +```xml + + + + role1 + role2 + role3 + + ... + +``` + +Corresponding settings for the Arthur IdP config YAML `assertionAttributes` for the `roleAttribute` field: + +```yaml + assertionAttributes: + roleAttribute: + name: "Idp_user_groups" + useAllAttributeValues: True +``` + +### Parsing User Groups from a String Attribute Value + +This example shows how to parse a user's groups from a SAML assertion when the groups are in a single string +AttributeValue. +Example SAML assertion XML: + +```xml + + + + role1,role2,role3 + + ... + +``` + +Corresponding settings for the Arthur IdP config YAML `assertionAttributes` for the `roleAttribute` field: + +```yaml + assertionAttributes: + roleAttribute: + name: "Idp_user_groups" + deliminator: "," +``` + +### Parsing Specific Fields in a Single Attribute's AttributeValue List + +This example shows how to parse a user's information from a SAML assertion when all fields are in a single assertion +Attribute's list of AttributeValues. +Example SAML assertion XML: + +```xml + + + + John + Doe + (123) 456-7890 + 42 Wallaby Way, Sydney + johndoe@arthur.ai + 5678987654 + + ... + +``` + +Corresponding settings for the Arthur IdP config YAML `assertionAttributes` for the user information field: + +```yaml + assertionAttributes: + firstNameAttribute: + name: "employeeInfo" + index: 0 + lastNameAttribute: + name: "employeeInfo" + index: 1 + emailAttribute: + name: "employeeInfo" + index: 4 + userIdAttribute: + name: "employeeInfo" + index: 5 +``` + diff --git a/files/arthur-docs-markdown/platform-management/access-control-overview/standard_access_control.md.txt b/files/arthur-docs-markdown/platform-management/access-control-overview/standard_access_control.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7746d1be0bde54160f2fe21cbff6bb2fda452e60 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control-overview/standard_access_control.md.txt @@ -0,0 +1,76 @@ +# Arthur Standard Access Control Overview + +In both SaaS and On-prem installations, Arthur ships with a build-in access control system that can be used to manage +users, permissions, and access to organizations. This system has different capabilities than the SSO based paradigm. If +your installation is using SSO, please see the {doc}`sso-access-control/index`. + +## Authentication + +Users authenticate to Arthur using a username and password, which is set when their account is created and can be +changed later in the UI. Users can also use +the [login API endpoint](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/auth/paths/~1login/post) to +retrieve a token for use with Arthur APIs. + +Applications and automated systems can authenticate with Arthur using API keys, which can be created in the Arthur UI +from the organization menu in the upper right corner then clicking on Manage API Keys. + +```{note} +Note: it is not recommended to use API-keys for non-automated use cases as they are not tied to user +identities and can obscure who is performing actions. As a best practice, use API keys minimally only in the systems +that need automated access, and be sure to create a rotation practice to ensure safe keeping. +``` + +![manage-api-keys](/_static/images/manage-api-keys.png "Organization Menu") + +## Authorization (RBAC) + +The Arthur standard access control system uses role-based access control (RBAC) with a set of pre-defined roles. +The available roles for users are `User`, `Model Owner`, `Administrator`, and `SuperAdmin`. If enrolled in multiple +organizations, the user can have a different role in each organization. For a full list of permissions for these 4 +standard roles, please reference {doc}`here `. + +* `User`: Has read-only access to the models and data within the organization. +* `Model Owner`: Can onboard new models in the enrolled organization as well as send data including reference data, + inferences, and ground truth. +* `Administrator`: Organization level administrator that has access to manage users and models within the organization. +* `Super Admin`: Has full access to all data, models, and actions on the platform. Can create new organizations and + manage users. Only available on-prem. + +```{note} +If your installation uses SSO, you can take advantage of creating custom roles to fine-tune user +access to Arthur resources. See {doc}`sso-access-control/custom_rbac` for more information. +``` + +## Adding Users to an Organization in the UI + +To complete this section, you must have the "Administrator" role in your organization. + +In the upper right corner, click on the organization menu, then click "Manage Members". From this screen, you can enter +the emails of additional users to add to the organization, manage the roles of existing users, and remove users from the +organization. + +```{note} +In order for email-based user invites to work, your installation must have an email integration set up. If +not, you can use the +[Arthur API](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/users/paths/~1users/post) +to create user accounts directly in your organization. +``` + +## Adding Users to an Organization in the API + +Arthur also supports managing users via automated workflows using the REST API. In order to create a user in +your organization, you will need to have Administrator privileges in that organization, or have access to the superadmin +user for your Arthur on-prem installation. The following APIs are helpful for managing users: + +- [Create a New User](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/users/paths/~1users/post) +- [Update User/Change User Password](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/users/paths/~1users~1%7Buser_id%7D/patch) +- [Send an Email Invite to a New User](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/users/paths/~1users~1invite_users/post) + + +## Switching Between Organizations + +If a user is invited to multiple organizations, they will have the ability to switch between them in the UI. +User can click on the organization menu in the upper right corner, and choose one of the other available organizations +from that menu to switch to it. If no other organizations appear, that user does not have access to any other +organizations. + diff --git a/files/arthur-docs-markdown/platform-management/access-control/authenticating_with_multiple_organizations.md.txt b/files/arthur-docs-markdown/platform-management/access-control/authenticating_with_multiple_organizations.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..cafdb118029b7836b944266878d3b3b70b08bcd5 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control/authenticating_with_multiple_organizations.md.txt @@ -0,0 +1,3 @@ +# Access Control + +The access control documentation has moved. Please see the new guides in {doc}`../access-control-overview/index` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control/authentication.md.txt b/files/arthur-docs-markdown/platform-management/access-control/authentication.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..cafdb118029b7836b944266878d3b3b70b08bcd5 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control/authentication.md.txt @@ -0,0 +1,3 @@ +# Access Control + +The access control documentation has moved. Please see the new guides in {doc}`../access-control-overview/index` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control/authorization_custom.md.txt b/files/arthur-docs-markdown/platform-management/access-control/authorization_custom.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..cafdb118029b7836b944266878d3b3b70b08bcd5 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control/authorization_custom.md.txt @@ -0,0 +1,3 @@ +# Access Control + +The access control documentation has moved. Please see the new guides in {doc}`../access-control-overview/index` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control/authorization_standard.md.txt b/files/arthur-docs-markdown/platform-management/access-control/authorization_standard.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..cafdb118029b7836b944266878d3b3b70b08bcd5 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control/authorization_standard.md.txt @@ -0,0 +1,3 @@ +# Access Control + +The access control documentation has moved. Please see the new guides in {doc}`../access-control-overview/index` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/access-control/index.md.txt b/files/arthur-docs-markdown/platform-management/access-control/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..495992620cb224f44954c15c09117a9642475b76 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/access-control/index.md.txt @@ -0,0 +1,19 @@ +--- +orphan: true +--- +[//]: # (This folder was the old structure of the access control docs. +The file structure was kept to maintain any customer bookmarks and point them to the new documentation.) + +# Access Control + +The access control documentation has moved. Please see the new guides in {doc}`../access-control-overview/index` + +```{toctree} +:maxdepth: 2 +:hidden: true + +Authentication +Standard Authorization +Custom Authorization +Authenticating With Multiple Organizations +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/index.md.txt b/files/arthur-docs-markdown/platform-management/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a6e1350b821b4c4c7d60dfa300025865fdf566dd --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/index.md.txt @@ -0,0 +1,33 @@ +(platform_management)= + +# Platform Management + +This section covers administration of the Arthur platform. Here you will find information on Arthur's access control, +user management, installation, and maintenance. Arthur is offered as a hosted SaaS platform and on-prem solution, +deployable to existing Kubernetes clusters, virtual machines, and bare metal servers. + +## {doc}`access-control-overview/index` + +This section shows how to configure the access and permissions for your various Arthur users within your organization. + +## {doc}`installation/index` + +This section shows how to install the necessary components for integrating Arthur into your platform. + +## {doc}`ongoing-maintenance/index` + +This section covers information for platform administrators responsible for ongoing maintenance of the Arthur platform. + +## {doc}`reference/index` + +This section contains references to configuration templates and permission sets for managing your Arthur usage. + +```{toctree} +:maxdepth: 2 +:hidden: + +Access Control +Installation +Ongoing Maintenance +Reference +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/.DS_Store b/files/arthur-docs-markdown/platform-management/installation/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..939cc50e3bee655b657c1fb7b66f2565d87f3eae Binary files /dev/null and b/files/arthur-docs-markdown/platform-management/installation/.DS_Store differ diff --git a/files/arthur-docs-markdown/platform-management/installation/externalize_postgres.md.txt b/files/arthur-docs-markdown/platform-management/installation/externalize_postgres.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3399dfa72fa4f46282cd342ef48e191b54f27142 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/externalize_postgres.md.txt @@ -0,0 +1,38 @@ +# Externalizing the Relational Database + +If desired, you can bring your own Postgres instance to use as your Arthur's relational database. Follow the steps +on this page to prepare your Postgres instance. + +First, deploy your Postgres instance in your desired environment with appropriate ingress firewall configuration. + +Create databases for the Arthur platform. +``` +CREATE DATABASE arthurai +CREATE DATABASE alert_service; +CREATE DATABASE dataset_service; +CREATE DATABASE metric_service; + +-- for stand alone instance +CREATE USER arthurai WITH PASSWORD 'SuperSecret'; +-- for RDS instance +CREATE ROLE arthurai WITH PASSWORD 'SuperSecret' LOGIN; + +REVOKE ALL PRIVILEGES ON DATABASE postgres FROM arthurai; +GRANT ALL PRIVILEGES ON DATABASE arthurai TO arthurai; +GRANT ALL PRIVILEGES ON DATABASE alert_service TO arthurai; +GRANT ALL PRIVILEGES ON DATABASE dataset_service TO arthurai; +GRANT ALL PRIVILEGES ON DATABASE metric_service TO arthurai; +``` + +If you have been using the embedded database and you wish to switch to using an external Postgres, backup the embedded +database and restore it to the new external Postgres with `pg_dump` and `pg_restore`. + +### Connecting to the database using SSL/TLS + +If your postgres instance supports SSL/TLS connections, and you want to connect to your external database +with an encrypted connection, you simply need to set `Database SSL Mode` in the initial configuration. By default, this +is set to `disable`. However, you can enable an encrypted connection using the value `require`. + +```{note} +An externally managed Postgres instance is strongly recommended for production-grade installs. +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/high_availability.md.txt b/files/arthur-docs-markdown/platform-management/installation/high_availability.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..1938b71f8486834cf73e1c514dd8f57b86e69410 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/high_availability.md.txt @@ -0,0 +1,54 @@ +# Setting up for High Availability + +## Introduction + +The Arthur Platform is built to run in a High Availability configuration, ensuring that the application can function +in the event of a Data Center outage, hardware outages, or other similar infrastructure issues. + +In order to take advantage of this, there are a few requirements in how your infrastructure is setup: + +1. Installing across 3 Availability Zones +2. Specifying the correct Instance Types +3. Configuring the cluster for Auto-scaling + +## Notes about this document + +```{note} +Note that this document is written using AWS terminology, as this is one of the environments/infrastructure that Arthur uses +internally for our environments. However, these setup steps should work across various cloud providers using similar features. +``` + +```{note} +Note that this document is written with the pre-requisite that you are installing Arthur in a High Availability configuration. +At the minimum, this means that there should be 3 instances across which Arthur is deployed. +``` + +## Installing across 3 Availability Zones + +In order to ensure continuous operation during an Availability Zone (AZ) outage, Arthur must be installed on a cluster +that has 3 Availability Zones. This ensures that in the event of one AZ outage that the rest of the components can still +operate. + +To do this in AWS, create 3 separate Auto-Scaling Groups (ASGs) - one for each AZ. You can configure which AZ an ASG provisions +instances into when you create the ASG. + +When Arthur deploys, the stateful services (eg: databases, messaging queues, etc.) will be balanced across the 3 AZs automatically using +kubernetes pod anti-affinity rules (pods will not schedule onto nodes where there already exists another pod that is of the same component). + +## Specifying the correct Instance Types + +Generally speaking, the best way to ensure you have deployed the correct Instance Types is to monitor resource utilization across the cluster +to determine when your services are hitting resource limits. + +When initially configuring a cluster for Arthur, we recommend 3 nodes, where each node has at least 16 vCPUs and 64G of RAM (eg: an `m5a.4xlarge` instance type). +This is a good starting point for a general-purpose cluster that will grow with your production usage. + +## Configuring the cluster for Auto-scaling + +Arthur's stateless components horizontally auto-scale, but in order to take the maximum advantage of this, you will need to configure and install +an additional component that performs node autoscaling (eg: adding more instances). + +AWS specifies how to setup cluster autoscaling in their [documentation](https://docs.aws.amazon.com/eks/latest/userguide/autoscaling.html). + +Generally speaking, it involves setting up an IAM role and granting permissions to autoscale the cluster, and then installing a third-party component +to perform the autoscaling (eg: [cluster-autoscaler](https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/cloudprovider/aws/README.md) diff --git a/files/arthur-docs-markdown/platform-management/installation/index.md.txt b/files/arthur-docs-markdown/platform-management/installation/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ada84cbc7a59922ca803488ec86f49d37a4d70fd --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/index.md.txt @@ -0,0 +1,34 @@ +# Installation + +Arthur can be installed to existing Kubernetes clusters (K8s) or virtual machines (VM). For both Kubernetes and virtual machine deployments, Arthur supports two types of installation methods, online and airgapped. The online method allows fast and continuous differential upgrades. The airgapped install supports environments where the cluster has no outbound internet connectivity. + +## {doc}`Installation Requirements ` +This page covers the requirements needed in your system to deploying Arthur within your system. + +## {doc}`Platform Readiness FAQ ` +This page covers some of the most frequently-asked questions about setting up Arthur for on-premises installation. + +## {doc}`Configuring for High Availability ` +This page covers how to configure your infrastructure to support running Arthur as a High Availability Application. + +## {doc}`kubernetes-installation/index` +This section shows how to install Arthur into a Kubernetes cluster. + +## {doc}`vm-installation/index` +This section shows how to install Arthur into a virtual machine. + +## {doc}`Externalize Postgres ` +This page shows how to set up a Postgres instance to use as your Arthur's relational database. + + +```{toctree} +:maxdepth: 2 +:hidden: + +Installation Requirements +Platform Readiness +Kubernetes Installation +Virtual Machine Installation +Configuring for High Availability +Externalize Postgres +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/index.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3479247d96cff3a59bd120c9da56a50ca1164b4b --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/index.md.txt @@ -0,0 +1,31 @@ +# Kubernetes Installation + +This section covers the steps required for installing Arthur on a Kubernetes cluster. There are separate steps required for online and airgapped installations. An additional set of instructions are also available for installing Arthur that’s scoped within a K8s namespace. + +## {doc}`kubernetes-preparation/index` +This section shows how to configure a Kubernetes cluster to install Arthur. + +## {doc}`k8s_install_online` +This page shows how to install Arthur into an online Kubernetes installation. + +## {doc}`k8s_install_airgapped` +This page shows how to install Arthur into an airgapped Kubernetes installation. + +## {doc}`k8s_install_airgapped_cli` +This page shows how to install Arthur into an online Kubernetes installation via a command-line interface. + +## {doc}`k8s_install_namespace_scoped` +This page shows how to install Arthur into a Kubernetes cluster with namespace scoped privileges. + + +```{toctree} +:maxdepth: 2 +:hidden: + +Configuring Kubernetes +Online +Airgapped +Airgapped CLI +Namespace Scoped + +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2c55ea7025bd6b04051b77f14577b3336d62a4fa --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped.md.txt @@ -0,0 +1,166 @@ +# Airgap Kubernetes Cluster (K8s) Install + +Make sure your K8s cluster is ready for Arthur platform installation by following +{doc}`the K8s preparation guide `. + +### **Preparing Container Registries** + +Prepare your private container image registry for Arthur artifacts by creating the following list of repositories: + +Admin Console: +``` +arthurai/dex +arthurai/kotsadm +arthurai/kotsadm-migrations +arthurai/local-volume-fileserver +arthurai/local-volume-provider +arthurai/minio +arthurai/postgres +``` + +Application: +``` +arthurai/alert-service +arthurai/alpine +arthurai/api-service +arthurai/argocli +arthurai/argoexec +arthurai/aws-cli +arthurai/beta-client +arthurai/busybox +arthurai/clickhouse-operator +arthurai/clickhouse-server +arthurai/client +arthurai/cp-kafka +arthurai/cp-kafka-connect +arthurai/cp-schema-registry +arthurai/cp-zookeeper +arthurai/custom-hpa +arthurai/dataset-service +arthurai/ingestion-service +arthurai/kafka-connect-monitor +arthurai/kafka-exporter +arthurai/kafka-prometheus-jmx-exporter +arthurai/kubectl +arthurai/mc +arthurai/metric-service +arthurai/metrics-exporter +arthurai/minio +arthurai/model-server +arthurai/model-server-controller +arthurai/postgresql +arthurai/python-jobs +arthurai/python-spark-jobs +arthurai/pytorch-jobs +arthurai/query-service +arthurai/redis +arthurai/scala-spark-jobs +arthurai/schema-service +arthurai/workflow-controller +arthurai/zookeeper-exporter +``` + +As an example, here's how you can create a new `arthurai/alert-service` repository on AWS ECR. +```shell +export AWS_REGION= +aws ecr create-repository --repository-name=arthurai/alert-service +``` + +### **Download Installation Files** + +Go to the download portal using the URL and the password provided by Arthur. + +Select the "Bring my own cluster" option. +![.png image](/_static/images/platform/download_portal_airgap_existingk8s.png) + +Click the “Download license” button to download your license in YAML file. + +Download the "KOTS Airgap Bundle" and the "arthur Airgap Bundle". + +### **Setup for Installation** + +Make sure you're in the correct kubectl environment context before running the installer. +```shell +kubectl config current-context +``` + +Install the KOTS kubectl extension on your local machine: +```shell +curl https://kots.io/install | bash +``` + +If the Linux workstation you're running `kubectl` from is also in the airgap environment, download the "KOTS CLI" from the download portal and install it like below: +```shell +tar zxf kots_linux_amd64.tar.gz +# move it to a location that's on your path +sudo mv kots /usr/local/bin/kubectl-kots +``` + +```{note} +The "KOTS CLI" and "KOTS Airgap Bundle" must be installed at the same time and therefore will be on the same version. +``` +```shell +kubectl kots version +``` + +If your workstation is a Mac, you can download the latest version of Kots CLI Darwin binary from [https://kots.io/](https://kots.io/). + +### **Start Installation** + +Push the Admin Console images to your private registry: +```shell +kubectl kots admin-console push-images ./kotsadm.tar.gz [Your private registry host]/arthurai \ + --registry-username [Read-Write Username] \ + --registry-password [Read-Write Password] +``` + +As an option, you can also pre-upload the application images to your private registry before running the installer: +```shell +kubectl kots admin-console push-images ./arthur-x.x.x.airgap [Your private registry host]/arthurai \ + --registry-username [Read-Write Username] \ + --registry-password [Read-Write Password] +``` + +Install the Admin Console (see here for {doc}`Namespace-Scoped Installs `): +```shell +kubectl kots install arthur \ + --no-port-forward \ + --namespace arthur \ + --shared-password [Provide an Admin Console password] \ + --kotsadm-namespace arthurai \ + --kotsadm-registry [Your private container image repository] \ + --registry-username [Read-Write Username] \ + --registry-password [Read-Write Password] +``` + +Create a port forwarding tunnel to Admin Console. Go to `http://localhost:8800` to access the Admin Console: +```shell +kubectl kots admin-console --namespace arthur +``` + +Follow the instructions on the Admin Console to complete your installation by providing the private registry details and `arthur-x.x.x.airgap` bundle. +![.png image](/_static/images/platform/install-airgap.png) + +```{note} +The upload process can take couple of hours so ensure your laptop does not go to sleep. You may follow the instructions {doc}`here ` to install the Admin Console and Arthur app programmatically using the CLI only. +``` + +Configure Arthur. +![.png image](/_static/images/platform/configure.png) + +### **Verify Installation** + +Monitor the Admin Console dashboard for the application status to become **Ready**. + +![.png image](/_static/images/platform/dashboard.png) + +To see the progress of the deployment, monitor the deployment status with `kubectl` CLI: +```shell +kubectl get deployment,statefulset,pod -n arthur +``` + +If anything is showing Pending, it is likely you need to add more/bigger nodes to your cluster. + +### **Customize Installation** + +Configure graphs on Admin Console by clicking on the `Configure Prometheus Address` button and providing your Prometheus endpoint (e.g. `http://kube-prometheus-stack-prometheus.monitoring.svc.cluster.local:9090`). diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped_cli.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped_cli.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..070ae41b774a258d1aafc9d73690f2a52a908025 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_airgapped_cli.md.txt @@ -0,0 +1,35 @@ +# Airgap Kubernetes Cluster (K8s) Install with CLI + +If you prefer to install programmatically using CLI only, follow the steps below. + +Prepare a `config.yaml` file using {doc}`the configuration template `. + +Deploy the application by running the below `kubectl` command: +```shell +kubectl kots install arthur \ + --no-port-forward \ + --namespace arthur \ + --shared-password [Provide an Admin Console password] \ + --license-file ./license.yaml \ + --config-values ./config.yaml \ + --airgap-bundle ./arthur-x.x.x.airgap \ + --kotsadm-registry [Your private container image repository] \ + --kotsadm-namespace arthurai \ + --registry-username [Read-Write Username] \ + --registry-password [Read-Write Password] +``` + +`shared-password` is the Admin Console password. + + +## Installing a specific version of Arthur + +To install a specific version of Arthur, you would run the same command as above (following the same steps to prepare the configuration), with the inclusion of the +`--app-version-label` flag. This flag allows you to specify which specific version of Arthur you want to install (eg: to setup a sandbox environment on the same version +as production). + +To determine which versions of Arthur are available, you can run: + +``` +kubectl kots get versions arthur -n +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_namespace_scoped.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_namespace_scoped.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e421caa238bc258dd5dea6edb4a7cb0304685d89 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_namespace_scoped.md.txt @@ -0,0 +1,71 @@ +# Kubernetes Cluster (K8s) Install with Namespace Scope Privileges + +If you would like to install the Arthur platform with namespace scoped privileges, there are certain components that will fail since they will need cluster level access. +These cluster-level components are CRDs ([Custom Resource Definitions](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/)) which are _**required**_ for proper functioning and operation of the Arthur platform. However, these CRDs only need to be installed once with cluster admin privileges, and elevated access is not required for normal usage of the platform. + +```{note} Both the Admin Console and Arthur application can be installed at the cluster-level or namespace-scope independent of each other. +``` + +### CRDs leverage by Arthur Platform + +The Arthur platform makes use of the following two CRDs: +1. **Argo Workflows** : Kubernetes-native Open-source workflow manager +1. **ClickHouse Operator** : Column-oriented OLAP datastore + +## Installing Admin Console within a Namespace + +By default, the Admin Console is installed at the Cluster level, available in all namespaces. If you would like to install the Admin Console only within a specific namespace, you can use the following flag to the `kots` command: +```shell +kubectl kots install arthur \ + --use-minimal-rbac + --skip-rbac-check +``` + +Since the Admin Console will not have access to the Cluster, certain Preflight checks will fail. It is the responsibility of the Cluster Admin to ensure sufficient resources are provisioned with the correct version of K8s. + +## Installing Cluster-level CRDs for Arthur, from Nexus + +Since the Arthur platform requires CRDs for normal operation, these will need to be installed by the Cluster Admin prior to installing Arthur itself, in no particular order. The instructions below show how you can download the CRD charts from our publicly hosted repository. + +* Argo Workflows: +```shell +helm repo add arthurai-released https://repository.arthur.ai/repository/charts --username --password +helm install argo-workflows-crd arthurai-released/argo-workflows-crd --version 0.19.1-arthur-1 +``` + +* ClickHouse Operator: +```shell +helm repo add arthurai-released https://repository.arthur.ai/repository/charts --username --password +helm install clickhouse-operator-crd arthurai-released/clickhouse-operator-crd --version 0.19.2-arthur-1 +``` + +```{note} Please reach out to our Sales Team if you do not have credentials to our Nexus repository. +``` + +## Installing Cluster-level CRDs for Arthur, from Airgap Bundle + +If you are in an airgapped environment with no access to the public internet, the CRD charts are also available in the Airgap bundle provided to you. The instructions below show how you can extract the charts from the Airgap bundle. + +```shell +tar -xvf arthur-.airgap +cd arthur- +tar -xvf app.tar.gz +cd app +``` + +* Argo Workflows: +```shell +helm install argo-workflows-crd argo-workflows-crd-0.14.0-arthur-2.tgz +``` + +* ClickHouse Operator: +```shell +helm install clickhouse-operator-crd arthurai-released/clickhouse-operator-crd-0.18.4-arthur-2.tgz +``` + +You can verify the CRDs have been installed successfully, by executing the following command: +```shell +kubectl get crd | grep -iE 'argo|clickhouse' +``` + +Now that we have the pre-reqs installed with elevated access, we can now switch over to namespace-scoped access to complete the installation either {doc}`using the Admin Console ` or {doc}`using the CLI `. diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_online.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_online.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..5ae69d1a5aad1744b77ce206e536281d87626221 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/k8s_install_online.md.txt @@ -0,0 +1,59 @@ +# Online Kubernetes Cluster (K8s) Install + +Make sure your K8s cluster is ready for Arthur platform installation by following {doc}`the K8s preparation guide `. + +### **Download Installation Files** + +Go to the download portal using the URL and the password provided by Arthur. + +Click the "Download license" button to download your license in YAML file. + +### **Setup for Installation** + +Make sure you're in the correct kubectl environment context before running the installer. + +Install the KOTS kubectl extension on your local machine: +```shell +curl https://kots.io/install | bash +``` + +### **Start Installation** + +Run the Admin Console installer and login on your browser at `localhost:8800` via the provided port forwarding tunnel: +```shell +kubectl kots install arthur +``` +For Namespace-Scoped Installs, follow this {doc}`guide `. + +When you need to re-create the tunnel to Admin Console, run: +```shell +kubectl kots admin-console --namespace +``` + +Upload your license file. +![.png image](/_static/images/platform/license.png) + +On the following screen, click on the link to install Arthur from the Internet. +![.png image](/_static/images/platform/install-online.png) + +Configure Arthur. +![.png image](/_static/images/platform/configure.png) + +Review the preflight checks to make sure that your machine meets the minimum requirements before you proceed with the installation. + +### **Verify Installation** + +Monitor the admin console dashboard for the application status to become **Ready**. + +![.png image](/_static/images/platform/dashboard.png) + +To see the progress of the deployment, monitor the deployment status with `kubectl` CLI: +```shell +kubectl get deployment,statefulset,pod -n +``` + +If anything is showing Pending, it is likely you need to add more/bigger nodes to your cluster. + +### **Customize Installation** + +Configure graphs on Admin Console by clicking on the `Configure graphs` button and providing your Prometheus endpoint (e.g. `http://kube-prometheus-stack-prometheus.monitoring.svc.cluster.local:9090`). diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/index.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d470cd8f89f29020c7349bc20e55feb84deee918 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/index.md.txt @@ -0,0 +1,19 @@ +# Kubernetes Installation Preparation + +This section covers the steps required to prepare an existing Kubernetes cluster for installing the Arthur platform. + +## {doc}`k8s_install_prep` +This page shows the basic process of configuring an existing K8s cluster for installing the Arthur platform. + +## {doc}`k8s_install_prep_aws` +This page shows the additional steps involved in configuring an Amazon AWS EKS cluster for installing the Arthur platform. + + +```{toctree} +:maxdepth: 1 +:hidden: + +Configuring Kubernetes +Additional Configurations for Amazon AWS + +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..52a9c5f3b6aae2f31effe841352b4d1ae377c533 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep.md.txt @@ -0,0 +1,135 @@ +# Kubernetes Cluster (K8s) Install Preparation + +This is a guide to help you prepare your existing Kubernetes cluster for installing the Arthur platform. +The examples use Helm 3. + +Make sure you're in the correct `kubectl` environment context before running the installer. + +## **Install Prometheus** + +Example: +```shell +helm repo add \ + prometheus-community \ + https://prometheus-community.github.io/helm-charts +helm repo update +helm upgrade --install -n monitoring \ + --create-namespace \ + kube-prometheus-stack \ + prometheus-community/kube-prometheus-stack \ + --set prometheus.prometheusSpec.serviceMonitorSelectorNilUsesHelmValues=false +helm upgrade --install -n monitoring \ + --create-namespace \ + prometheus-adapter \ + prometheus-community/prometheus-adapter +``` + +Verify that Prometheus CRDs are installed: +```shell +kubectl api-resources | grep monitoring +``` + +Verify that Prometheus is up and running: +```shell +kubectl --namespace monitoring get pods -l "release=kube-prometheus-stack" +``` + +If everything is installed correctly, the following command should not return _"ServiceUnavailable"_: +```shell +kubectl get --raw /apis/custom.metrics.k8s.io/v1beta1 +``` + +(k8s_install_prep_install_ingress)= +## **Install Ingress** + +Example with Nginx: +```shell +helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx +helm repo update +helm upgrade --install -n ingress-system \ + --create-namespace \ + ingress-nginx \ + ingress-nginx/ingress-nginx +``` + +[Optional] To add an AWS managed SSL certificate, create a `values.yaml` file with following contents - +```shell +controller: + service: + annotations: + service.beta.kubernetes.io/aws-load-balancer-backend-protocol: http + service.beta.kubernetes.io/aws-load-balancer-connection-idle-timeout: "60" + service.beta.kubernetes.io/aws-load-balancer-cross-zone-load-balancing-enabled: "true" + service.beta.kubernetes.io/aws-load-balancer-ssl-cert: + service.beta.kubernetes.io/aws-load-balancer-ssl-ports: https + service.beta.kubernetes.io/aws-load-balancer-type: elb + service.beta.kubernetes.io/aws-load-balancer-ssl-negotiation-policy: ELBSecurityPolicy-TLS-1-2-2017-01 + service.beta.kubernetes.io/aws-load-balancer-internal: true # optional annotation that creates a non-internet-facing loadbalancer + targetPorts: + http: "tohttps" + + allowSnippetAnnotations: "true" + config: + http-snippet: | + server { + listen 2443; + return 308 https://$host$request_uri; + } + use-forwarded-headers: "true" + + containerPort: + http: 8080 + tohttps: 2443 + https: 80 +``` +Upgrade or install the helm chart with the `values.yaml` you created. +```shell +helm upgrade --install -n ingress-system \ + --create-namespace \ + ingress-nginx \ + ingress-nginx/ingress-nginx \ + -f values.yaml +``` + +If you need to install Nginx in the same namespace as Arthur (not recommended) and want to use our network-policy to restrict ingress to the Arthur application, use the below command to add labels to the pods and services. The network-policy allows traffic between pods and services that have these labels. +```shell +helm upgrade --install -n arthur --set controller.podLabels.network-app=arthurai,controller.service.labels.network-app=arthurai,defaultBackend.podLabels.network-app=arthurai,.service.labels.network-app=arthurai \ + ingress-nginx \ + ingress-nginx/ingress-nginx +``` + +Look up the hostname for the Ingress and configure it in your DNS (e.g. `arthur.mydomain.com`). +```shell +kubectl get svc -n ingress-system ingress-nginx-controller -ojsonpath='{.status.loadBalancer.ingress[*].hostname}' +``` + +## **Install Metrics Server** + +Example: +```shell +helm repo add bitnami https://charts.bitnami.com/bitnami +helm repo update +helm upgrade --install -n monitoring \ + --create-namespace \ + metrics-server \ + bitnami/metrics-server \ + --set apiService.create=true \ + --set --extraArgs.kubelet-preferred-address-types=InternalIP +``` + +Verify that you can retrieve metric snapshots. +```shell +kubectl top node +``` + +## **Configure the cluster-autoscaler** + +In a production environment, it is vital to ensure that there are enough resources (memory and cpu) available for pods to get scheduled on the Kubernetes cluster. Please follow the instructions for your cloud provider to install the [cluster-autoscaler](https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler) on your cluster. + +Verify that the `cluster-autoscaler` is successfully installed. +```shell +kubectl get deployments -n kube-system | grep -i cluster-autoscaler +``` + +## **Cloud Provider-specific Configuration** +If installing on an existing Amazon AWS EKS, follow the additional steps {doc}`here `. \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep_aws.md.txt b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep_aws.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..cae37472b8f894ba268398fba15c4be444f49a12 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/kubernetes-installation/kubernetes-preparation/k8s_install_prep_aws.md.txt @@ -0,0 +1,126 @@ +# Deploying on Amazon AWS EKS + +This is a guide with additional steps to help you prepare your existing Amazon Elastic Kubernetes Service (Amazon EKS) cluster for installing the Arthur platform. +Ensure the initial steps detailed {doc}`here ` have already been applied to the cluster. + +## **Configure EKS EBS CSI driver** + +As of EKS 1.23, the Amazon Elastic Block Store (Amazon EBS) Container Storage Interface (CSI) driver needs to be installed explicitly. This driver allows EKS clusters to manage the lifecycle of EBS volumes for Persistent Volumes. For more information, see [Amazon Docs](https://docs.aws.amazon.com/eks/latest/userguide/ebs-csi.html). + +If you are deploying Arthur on EKS 1.23+, you will need to follow the instructions on [this page](https://docs.aws.amazon.com/eks/latest/userguide/managing-ebs-csi.html). + +Verify that the Add-On is successfully installed, by navigating to **AWS Console → EKS → Cluster → Add-Ons** or by running `helm list -A`, depending on your installation method. + +## **Optimizing the AWS EKS StorageClass** +Once the EKS EBS CSI driver is installed, you can take advantage of the `gp3` StorageClass type. This StorageClass is more [cost-effective and performant](https://aws.amazon.com/blogs/storage/migrate-your-amazon-ebs-volumes-from-gp2-to-gp3-and-save-up-to-20-on-costs/) than the previous `gp2` StorageClass. Apply the below YAML definition to your cluster: +```yaml + apiVersion: storage.k8s.io/v1 + kind: StorageClass + metadata: + annotations: + storageclass.kubernetes.io/is-default-class: "true" + name: gp3 + parameters: + type: gp3 + provisioner: ebs.csi.aws.com + reclaimPolicy: Delete + volumeBindingMode: WaitForFirstConsumer + allowVolumeExpansion: true +``` +```{note} +Ensure there is **_only one_** default StorageClass on the cluster. This is controlled by the `storageclass.kubernetes.io/is-default-class` annotation. +``` + +## **Supported AWS Service Authentication Mechanisms** +If using AWS services with Arthur such as S3 or SES, you will need to configure Arthur to authenticate with AWS. Arthur currently supports 3 authentication mechanisms: + +![iam auth](/_static/images/platform/iam_authentication.png) + +### AWS Access Keys +Access Keys only work with S3. If you want to use Access Keys you will need to provision an IAM user and a set of keys. Via [AWS IAM](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_users_change-permissions.html), you will need to grant this user read/write access to the S3 storage bucket that you plan on using with Arthur. Selecting the Access Keys option will expand the Blob Storage section of the config page where you will be able to enter your Access key, Secret Access key ID, and the S3 bucket. + +![s3](/_static/images/platform/s3_access_keys.png) + +## IRSA + +We recommend using [IRSA](https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html) to authenticate Arthur with AWS as it is the most secure, and is the only mechanism that supports SES. Using this methodology will require a bit of AWS platform work in preparation for Arthur. You can follow these [AWS docs](https://docs.aws.amazon.com/eks/latest/userguide/associate-service-account-role.html) which will show you how to do this setup via eksctl or the AWS CLI, or you can automate this via your internal Infrastructure as Code. + +The role that you create will need to have S3 read/write privileges on the bucket you want to use with Arthur, and permissions to send email via your SES entity. Example snippets are as below: + +### Sample IAM policy for S3 access: +``` +{ + "Statement": [ + { + "Action": [ + "s3:PutObject", + "s3:GetObject", + ... + ], + "Effect": "Allow", + "Resource": [ + "arn:aws:s3:::/*", + "arn:aws:s3:::" + ], + .... + }, +``` + +### Sample IAM policy for SES access: +``` + "Action": [ + "ses:SendTemplatedEmail", + "ses:SendEmail", + "ses:SendCustomVerificationEmail", + "ses:SendBulkTemplatedEmail", + "ses:SendBulkEmail", + "ses:SendBounce" + ], + "Effect": "Allow", + "Resource": "*", + "Sid": "sesSendEmails" + }, +``` + +This role will also need to have a trust relationship to the OIDC provider of your EKS cluster, specifying the Arthur service accounts. See the linked docs above for a further explanation. An example snippet of this is: +``` +{ + "Version": "2012-10-17", + "Statement": [ + { + "Sid": "", + "Effect": "Allow", + "Principal": { + "Federated": "arn:aws:iam::123456789012:oidc-provider/oidc.eks.us-east-2.amazonaws.com/id/ABDCEF......" + }, + "Action": "sts:AssumeRoleWithWebIdentity", + "Condition": { + "StringEquals": { + "oidc.eks.us-east-2.amazonaws.com/id/ABDCEF:sub": [ + "system:serviceaccount::arthurai-", + "system:serviceaccount::arthurai--helm-hook" + ] + } + } + } + ] +} +``` + +Once this is all set up you can pass this role into Arthur via the config page. This sets the role in the Arthur Service Accounts specified above, which enables Arthur's pods to authenticate with AWS via the role, and the permissions you created. Be sure to use the exact formatting shown below: + +![irsa](/_static/images/platform/irsa.png) + +Proceed to the Blob Storage section of the Arthur config page to specify the S3 bucket + +### SES + +To utilize AWS SES for Arthur generated emails, you will need to configure IRSA as outlined in the above section. Once this is done navigate to the email configuration section of Arthur's config page. Select AWS SES, and then enter the region in which your SES entity is configured. As outlined above, the role associated with the cluster must have permissions on this SES entity. If the SES entity is in the same account as your cluster, and you do not need to utilize a different role such as for cross account permissions, do not enter a role in the second box. + +![ses](/_static/images/platform/ses.png) + +If your SES entity is in another Arthur account you will need to set up cross account privileges between roles. In the account of your SES entity (Account A) you will need to create an IAM role (Role A) that has send email permissions to SES as depicted above. Role A will also need to have a trust relationship with either the account that your cluster is in (Account B), the OIDC provider on your cluster as depicted above, or the IRSA role associated with your cluster. Additionally, the IRSA role that you created above in Account B, will also need to be granted STS assume role privileges on the role you are creating in Account A. + +Once all of this is set up, enter the role in the account that contains the SES entity (Account A), that the IRSA role should assume to send emails: + +![ses cross account](/_static/images/platform/ses_cross_account.png) diff --git a/files/arthur-docs-markdown/platform-management/installation/platform_readiness_faq.md.txt b/files/arthur-docs-markdown/platform-management/installation/platform_readiness_faq.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ceeec9a1dc767f7d88bd7eba5675df923cd5c6e --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/platform_readiness_faq.md.txt @@ -0,0 +1,96 @@ +# Platform Readiness for Existing Cluster Installs + +The Arthur platform can be installed on an on-prem or cloud-based pre-provisioned Kubernetes cluster, so all the data and controls adhere to existing corporate practices. + +## Arthur Cluster Installs FAQs + +### SysAdmin + +1. **What kind of privileges/hardware does the SysAdmin installing the Arthur platform need?** +The SysAdmin will need a workstation with the following requirements: + - running Linux or MacOS. The KOTS CLI installer does not support Windows. + - sudo/root access. To install the KOTS CLI plugin for `kubectl`. + - connection to the Kubernetes cluster, using `kubectl`, and privileges to deploy K8s Objects at either Cluster or Namespace scope (at least). + - (recommended) access to the Internet. For downloading the installer, plugins and fetching updates. + +1. **How can I download the artifacts required for installing the Arthur platform?** +All artifacts required for installing the Arthur platform are available on a customer-specific password-protected portal, which your sales team can give you access to. It is recommended that the portal is accessible from within your corporate network, since the artifacts are around mutiple GBs in size. + +1. **Does my kubernetes cluster need access to the internet?** +The Arthur platform can be installed without Internet access, once all the required files are downloaded and available locally. However, we recommend access to the Internet from the Kubernetes cluster for an efficient install and upgrade experience. Please inform your sales team about any network restrictions and optionally, if its possible to {ref}`whitelist specific URLs `. + +### Cloud Providers + +1. **Which Kubernetes distributions that Arthur supports out-of-the-box?** +Arthur is architected to run on any distribution of Kubernetes, however certain commercial distributions are untested. The Arthur application is validated/tested on: + - Amazon [AWS EKS](https://aws.amazon.com/eks/) + - Microsoft [Azure AKS](https://azure.microsoft.com/en-us/services/kubernetes-service/) + +1. **Which cloud providers has Arthur been tested on?** +The Arthur platform has been tested on the following cloud providers: + - Amazon [AWS](https://aws.amazon.com/) + - Microsoft [Azure](https://azure.microsoft.com/en-us/) + +1. **What container runtimes does Arthur support?** +Containers in the Arthur Platform run on the following container runtimes: + - docker (slated to be [deprecated in Kubernetes 1.24](https://kubernetes.io/blog/2022/01/07/kubernetes-is-moving-on-from-dockershim/)) + - containerd + +### Kubernetes Server + +1. **What version(s) of Kubernetes Server does Arthur support?** +Arthur supports Kubernetes Server 1.19 through 1.22. + +1. **Can the Arthur platform be scoped to a dedicated namespace?** +The Arthur platform can be deployed and scoped to a specific namespace, though there are some cluster-level CustomResourceDefinitions that need to be pre-installed. See details [here](./kubernetes-installation/k8s_install_namespace_scoped). + +1. **What are the minimum resource requirements for operating the Arthur Platform?** +Optimal performance of the Arthur platform is ensured on a 6 node cluster (though test clusters can be provisioned with 3 nodes) with each node having 16 CPUs, 32GB Memory (RAM) and 1000 GB Storage with atleast 3000 IOPS. However, please reach out to your sales team for a tailored configuration custom to your projected workloads. + +1. **Is there a default StorageClass defined on the Kubernetes cluster?** +The Kubernetes cluster must have a default StorageClass defined before starting the Arthur platform installation. If a default StorageClass does not exist, adding the `storageclass.kubernetes.io/is-default-class: "true"` annotation to a StorageClass should remedy this requirement. + +1. **What Ingress Controller are you planning to use to access the Arthur platform? Is it already installed?** +The Arthur platform needs to expose a couple of services so the application is accessible outside the cluster. All [compatible Kubernetes Ingress controllers](https://kubernetes.io/docs/concepts/services-networking/ingress-controllers/) should work, though {ref}`Nginx Ingress Controller ` installed in a separate namespace is recommended. + +1. **Are there any SecurityContext requirements on the Kubernetes cluster?** +The Arthur platform is architected to leverage as few permissions as deemed necessary for optimal functioning. No container is run as root. All processes are owned by non-system users. Please reach out to your sales team if you have specific SecurityContext requirements. + +1. **Does Arthur support running on SELinux environments?** +The Arthur platform requires SELinux to be running in permissive mode, if enabled. + +1. **Are there any Network Policies configured on the Kubernetes cluster?** +Pods of the Arthur platform will need to communicate with each other. By default, pods [can communicate](https://kubernetes.io/docs/concepts/services-networking/network-policies/#default-policies) with each other. Please reach out to your sales team if you have custom Network Policies configured on the Kubernetes cluster. + +1. **How many IP addresses should be available for the Arthur Platform?** +The Arthur platform is architected to be scalable, using resources on-demand. Given the dynamic nature of the infrastructure involved, we recommend at least 128 IP address CIDR blocks attached to the relevant subnets. However, this number can increase as more models are onboarded to the platform. + +1. **Are there any namespace-level constraints enforced on the Kubernetes cluster?** +Please let your sales team know if there are any constraints configured at the namespace-level on the Kubernetes cluster, as this will help prepare for a smooth installation experience. + +1. **Are there any cluster-level constraints enforced on the Kubernetes cluster?** +Please let your sales team know if there are any specific cluster-level contraints configured on the Kubernetes cluster, as this will help prepare for a smooth installation experience. + +1. **Does the Kubernetes cluster have access to a private/public container registry?** +The Kubernetes cluster on which the Arthur platform will be installed must have connectivity to a container registry. The SysAdmin performing the installation must also have Read/Write access to the same container registry. + +1. **Does the Kubernetes cluster have access to a private/public Pypi/Conda registry?** +The Kubernetes cluster on which the Arthur platform will be installed must have connectivity to a Pypi/Conda registry, which ensures optimum utilization of the features of the platform. + +### Other Considerations + +1. **Does your enterprise have a software procurement process?** +Please keep your sales team informed of any software procurement process that maybe in place before installing new software, and potential turnaround times for such processes. + +1. **Do you want to deploy Arthur on infrastructure that isn't mentioned above (eg: Cloud Providers, Kubernetes Distributions, etc.)?** +If so, please inform your sales team as soon as possible so we can setup an architecture review between your platform team and Arthur's platform team. + +1. **Can any of the Arthur platform components be externalized, so its not managed by Arthur?** +The platform supports the use of AWS S3 as well as most S3 compatible systems as the Object/Blob store. The embedded metadata database can be replaced by a recent version of Postgres. +A managed service for S3 and/or Postgres is recommended for production-grade installs. + +1. **Can the Arthur platform be deployed on a Kubernetes cluster that is shared with other applications?** +The Arthur platform has been architected to be highly scalable and reliable. Based on usage (number of models) and load (data ingestion), pods are scaled in short periods of time to ensure efficient operation. As such, if other applications will be installed on the same Kubernetes platform, talk to your sales team about provisioning dedicated nodegroups for the cluster. + +3. **Does the Arthur platform support different organizations/business units using the same application?** +Yes. See our guide on [User and Org Management](../ongoing-maintenance/organizations_and_users). \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/installation/requirements.md.txt b/files/arthur-docs-markdown/platform-management/installation/requirements.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..0cb59d4db9ae5eae3658340199ee7395c79e5ab8 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/requirements.md.txt @@ -0,0 +1,84 @@ +# On-prem Deployment Requirements + +## General +* A DNS hostname +* TLS private key & certificate +* SMTP server (StartTLS supported) + +The minimum compute resource requirements in this documentation is for running a few small models in a non-production environment. Your production deployment will likely use more compute resources to achieve higher availability, performance and scalability. + +Arthur’s horizontally elastic architecture allows high throughput processing in both streaming and batch. The platform's auto-scaler mechanism self-manages resource utilization in optimized and cost-effective fashion. It automatically scales up and down based on compute resource requests by the platform activities as well as the lag observed in the data pipeline queue within the limits of the allocated hardware. This works best in a cloud infrastructure with a managed Kubernetes service that enables Arthur to also auto-scale the provisioned hardware (e.g. AWS EKS, Azure ASK). + +Storage volumes used for Arthur deployment should be encrypted with a data key using industry-standard data encryption (e.g. AES-256). This applies to the mounted disk volumes as well as the externalized storage, such as the S3 object storage and the relational database if any. + +## Kubernetes Install +* Kubectl-ing workstation: Linux or MacOS +* Kubernetes: 1.22 to 1.24 +* Runtime: containerd or Docker +* Namespace +* [Storage class](https://kubernetes.io/docs/concepts/storage/storage-classes/) + +### Minimum Node Group Resource +* 16 CPUs +* 32 GB RAM +* Storage with at least 3000 IOPS (>100GB recommended) + +### Permissions +When Arthur platform is installed, Kubernetes RBAC resources are created to allow the Admin Console to manage the application. +The kubectl-ing user who installs Arthur must have the wildcard privileges in the cluster. + +Refer to [this documentation](https://kots.io/vendor/packaging/rbac/#reference-objects) for the ClusterRole and ClusterRoleBinding that +will be created for the Admin Console. + +### Components +* Prometheus +* Ingress Controller (Nginx or Ambassador) +* Kubernetes Metrics Server +* Velero with Restic (Optional for managed backup and restore feature) + +For Airgapped installation only: +* An existing private container registry +* Existing private Python registries (PyPI, Anaconda) - only required for the model explanation feature + +## VM Install + +### Minimum Server Resource +* 16 CPUs +* 32 GB RAM +* Storage with at least 3000 IOPS (>100GB recommended) + +### Supported Operating Systems +The latest versions of the following Linux operating systems are supported. + +* Ubuntu +* RHEL + +Please do the following before running the installer on your VM for a smoother deployment experience: +* If SELinux is enabled, set it to the permissive mode +* Make sure the VM doesn't have any container runtime pre-installed, such as Docker or containerd + +### Ports for High Availability Configuration +* TCP ports 2379, 2380, 6443, 6783, 10250, 10251 and 10252 open between cluster nodes +* UDP ports 6783 and 6784 open between cluster nodes + +## Firewall Configurations +### Ingress +The TCP port 443 is the only entry point that Arthur exposes. + +### Egress +The platform requires access to any integrations (e.g. SMTP, IdP) as well as externalized components (e.g. Postgres, S3). + +#### For Airgap Installation +Your private container and Python registries must be accessible. + +(requirements_for_online_installation)= +#### For Online Installation +Access to container images and deployment manifest files from the below public registries are required. + +| Host | Existing Cluster | Embedded Cluster | +| ---------------------- | ----------------- | -----------------| +| Docker Hub | Required | Required | +| proxy.replicated.com | Required | Required | +| replicated.app | Required | Required | +| k8s.kurl.sh | Not Required | Required | +| amazonaws.com | Not Required | Required | diff --git a/files/arthur-docs-markdown/platform-management/installation/vm-installation/index.md.txt b/files/arthur-docs-markdown/platform-management/installation/vm-installation/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d6e7fa7ba53dcdb551271ae3e2b0067f0238424b --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/vm-installation/index.md.txt @@ -0,0 +1,21 @@ +# Virtual Machine Installation + +This section covers the steps required for installing Arthur on a virtual machine. We have included seperate steps required for online and airgapped installations. + +## {doc}`vm_install_online` +This page shows the basic process of installing Arthur on a virtual machine. + +## {doc}`vm_install_airgapped` +This page shows the basic process of installing Arthur on an airgapped virtual machine. + +## {doc}`vm_install_airgapped_cli` +This page shows the basic process of installing Arthur on an airgapped virtual machine via a command-line interface. + +```{toctree} +:maxdepth: 1 +:hidden: + +Online +Airgapped +Airgapped CLI +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped.md.txt b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..5ed34c14392852a64644bd9e29ff8c810297be1d --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped.md.txt @@ -0,0 +1,49 @@ +# Airgap Virtual Machine (VM) Install + +Go to the download portal using the URL and the password provided by Arthur. + +Select the "Embedded cluster" option. +![.png image](/_static/images/platform/download_portal_airgap_embedded.png) + +Click the “Download license” button to download your license in YAML file. + +Download the "Latest kURL embedded install" and the "Latest Arthur Airgap bundle". + +## Preparing the embedded cluster +Arthur leverages Kubernetes as the base. This step installs the base Kubernetes cluster and Arthur's Admin Console +on your VM with a single CLI command. + +First, upload the kURL embedded install bundle on your VM instance. +Example: +```shell +scp -i mykey.pem ~/Downloads/arthur.tar.gz ubuntu@hostname:arthur.tar.gz +``` + +Unpack the bundle and install the embedded Kubernetes cluster on your VM instance. +```shell +tar xvf arthur.tar.gz +cat install.sh | sudo bash -s airgap +``` + +Save the output from the install which includes the Kotsadm Admin Console URL and the password. +You now have a K8s cluster, kubectl CLI, and the Admin Console installed on your VM. + +## Deploying the application to the embedded cluster +Load the Admin Console UI on port 8800 from your browser using the Kotsadm URL and the password you recorded earlier. +Follow the instructions on the Admin Console to complete your installation by providing the `arthur-x.x.x.airgap` bundle and necessary configurations. + +Monitor the Admin Console dashboard for the application status to become **Ready**. + +![.png image](/_static/images/platform/dashboard.png) + +To see the progress of the deployment, monitor the deployment status with `kubectl` CLI on the VM: +```shell +# Reload your shell if you haven't +bash -l + +kubectl get deployment,statefulset,pod +``` + +If anything is showing Pending, it is likely you need to add more/bigger nodes to your cluster. + +**Note:** You may also follow the instructions {doc}`here ` to install the Admin Console and Arthur app programmatically using the CLI only. \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped_cli.md.txt b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped_cli.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..8811db64169a3b6c15c78f0a4ac88289b6242d14 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_airgapped_cli.md.txt @@ -0,0 +1,24 @@ +# Airgap Virtual Machine (VM) Install with CLI + +If you prefer to install programmatically using CLI only, follow the steps below. + +Upload the license file and the `arthur-x.x.x.airgap` bundle on your VM instance. + +Example: +```shell +scp -i mykey.pem ~/Downloads/Test\ Customer.yaml ubuntu@hostname:license.yaml +scp -i mykey.pem ~/Downloads/arthur-x.x.x.airgap ubuntu@hostname:arthur-x.x.x.airgap +``` + +Create a `config.yaml` file on the VM instance using {doc}`the configuration template `. + +Run this install command from your VM's SSH session: + +```shell + kubectl kots install arthur \ + --airgap-bundle ./arthur-x.x.x.airgap \ + --license-file ./license.yaml \ + --config-values ./config.yaml \ + --namespace arthur \ + --shared-password [The Kotsadm password you saved earlier] +``` diff --git a/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_online.md.txt b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_online.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..b18072b3fd3badfd1cbd0c6ac57ffe99be457990 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/installation/vm-installation/vm_install_online.md.txt @@ -0,0 +1,41 @@ +# Online Virtual Machine (VM) Install + +Go to the download portal using the URL and the password provided by Arthur. + +Click the "Download license" button to download your license in YAML file. + +SSH into your virtual machine (VM) and run the command below to install the Admin Console: +```shell +curl -sSL https://k8s.kurl.sh/arthur | sudo bash +``` + +Login to the Admin Console at `:8800` using the provided password in the install output. + +Follow the instruction to set up your secure connection with TLS certificate. + +Upload your license file. +![.png image](/_static/images/platform/license.png) + +Provide your configurations. +![.png image](/_static/images/platform/configure.png) + +Review the preflight checks to make sure that your machine meets the minimum requirements before you proceed with the installation. + +Monitor the dashboard for the application status to become **Ready**. + +![.png image](/_static/images/platform/dashboard.png) + +To see the progress of the deployment, monitor the deployment status with `kubectl` CLI: +```shell +# Reload your shell if you haven't +bash -l + +kubectl get deployment,statefulset,pod -n +``` + +If anything is showing Pending, it is likely you need to add more/bigger nodes to your cluster. + +When using `kubectl`, you might run into a permission issue loading the `kubernetes/admin.conf` file. Please remediate it by running the command below. +```shell +sudo chmod +r /etc/kubernetes/admin.conf +``` diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/audit_log.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/audit_log.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a926dae46361e6f31b72bada87bd04a0c62a6d78 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/audit_log.md.txt @@ -0,0 +1,112 @@ +# Audit Log + +The Arthur platform has the ability to produce an audit log of all calls to sensitive endpoints that include +models, organizations, RBAC, and uploading / modifying data. + +## Event Format + +Each event in the audit log has the following fields: + +| Field | Type | Notes | +|------------------|----------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| event_category | string | A description of the overarching category for this event. See the table below for a breakdown of the various categories. | +| event_type | string | An explanation of what kind of event occurred within the event_category. See the table below for a breakdown of the various types. | +| event_id | string | A unique ID for this event, currently in UUID format but this may change in the future. | +| timestamp | [string, int] | A timestamp in either Unix Epoch millisecond integer format or [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339) string format, depending on the point of integration. | +| organization_id | [string, null] | A string UUID of the organization if there is one associated with the event. | +| model_id | [string, null] | A string UUID of the model if there is one associated with the event. | +| user_id | [string, null] | A string ID of the user if there is one associated with the event. | +| user_type | [string, null] | A string description of the kind of user if there is one associated with the event. This can be one of: `service-account`, `arthur-managed`, or `idp-managed`. | +| http_path | [string, null] | A string HTTP path of the request that triggered the event if one exists. | +| http_method | [string, null] | A string HTTP method of the request that triggered the event if one exists. | +| http_status_code | [int, null] | An integer HTTP status code of the request that triggered the event if one exists. | + +## Logged Endpoints + +When enabled, Audit Logging will track all requests made to the following endpoints and set the Event Category and Event Type respectively in the audit log events. + +| Endpoint | Method | Event Category | Event Type | +|---------------------------------------|--------|-------------------------------|---------------------------------| +| /organizations | POST | events.arthur.ai/organization | created | +| /organizations/{organization_id} | DELETE | events.arthur.ai/organization | deleted | +| /models | POST | events.arthur.ai/model | created | +| /models/{model_id} | PUT | events.arthur.ai/model | updated | +| /models/{model_id} | DELETE | events.arthur.ai/model | deleted | +| /alerts/{alert_id}/notifications | POST | events.arthur.ai/alert | created | +| /models/{model_id}/inferences | POST | events.arthur.ai/ingestion | inference_data_received | +| /models/{model_id}/inferences | PATCH | events.arthur.ai/ingestion | ground_truth_data_received | +| /models/{model_id}/inferences/file | POST | events.arthur.ai/ingestion | inference_data_received | +| /models/{model_id}/reference_data | POST | events.arthur.ai/ingestion | reference_data_received | +| /models/{model_id}/batches/{batch_id} | PATCH | events.arthur.ai/ingestion | inference_data_batch_completed | +| /models/{model_id}/reference_data | PATCH | events.arthur.ai/ingestion | reference_data_upload_completed | +| /authorization/custom_roles | POST | events.arthur.ai/rbac | updated | +| /authorization/custom_roles | DELETE | events.arthur.ai/rbac | updated | + +A more thorough description of these endpoints is available at our [API documentation](https://docs.arthur.ai/api-documentation/v3-api-docs.html). + +## Integration with EventBridge + +The on-prem installation provides support for shipping the Audit Log to AWS EventBridge. In order to configure this, you will need the following: + +- **Bus Name**: Required. The name of the EventBridge bus. This should not be the full ARN of the bus. +- **Region**: Required. This is the AWS region where your EventBridge bus is located. +- **Source**: Optional. This value will be added to the EventBridge events "source" for all events. This defaults to "arthur-audit-log". +- **Detail Type**: Optional. This value will be added to the EventBridge events "detail-type" for all events. This defaults to "events.arthur.ai". + +An example of the events that are written to EventBridge look like the following +(this was captured via an EventBridge to CloudWatch Log Group rule and target): +```json +{ + "version": "0", + "id": "b87f2a3a-6be1-e1d9-bc94-720d60e0a9d8", + "detail-type": "events.arthur.ai", + "source": "arthur-audit-log", + "account": "1234567890", + "time": "2022-07-21T22:07:00Z", + "region": "us-east-2", + "resources": [], + "detail": { + "event_type": "created", + "event_category": "events.arthur.ai/model", + "event_id": "da2ec82d-f581-4e72-bb66-fc82504f2a7e", + "timestamp": "2022-07-21T22:06:59.683+0000", + "organization_id": "d579359a-7259-4397-a08b-3e36c212350f", + "model_id": "a950c9ad-6a1e-4042-8e47-461d13072da5", + "user_id": "df3fe374-26d7-4bd8-bf62-e04a6e078e2b", + "user_type": "arthur-managed", + "http_path": "/api/v3/models", + "http_method": "POST", + "http_status_code": 200 + } +} +``` + +### Configuration + +The EventBridge integration can be enabled on the Admin Console Config Page by: +1. Checking "Show Other Advanced Options" under the Other Advanced Options section +2. After that is checked, a new section will appear called "Audit Logging" +3. Check "Enable Audit Log" +4. Next a choice of persistence methods appears. Choose "AWS EventBridge" +5. Fill out the "Bus Name", "Region", "Event Source", and "Detail Type" fields that appear. +6. Click "Save config" and deploy the updated version + +### Required IAM Permissions + +In order to send events to AWS EventBridge, the Arthur IAM credentials or role will require the `events:PutEvents` +permission. Here is an example policy that grants that permission on a EventBridge bus called `arthur-events` in the +`us-east-2` region, in the `0123456789` AWS account. + +```json +{ + "Statement": [ + { + "Action": "events:PutEvents", + "Effect": "Allow", + "Resource": "arn:aws:events:us-east-2:0123456789:event-bus/arthur-events", + "Sid": "" + } + ], + "Version": "2012-10-17" +} +``` diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/backup.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/backup.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..39bdc9f9aaf63205a7f94d5093ff6f0dd0972a2a --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/backup.md.txt @@ -0,0 +1,845 @@ +# Arthur Platform Backup and Restore + +## Contents + +* Warnings +* Overview + * Overview - clickhouse-backup + * Overview - Velero + * Overview - Arthur (Argo)Workflows + * Overview - S3 +* Pre-requisites +* Installing - Velero + * Setup ServiceAccount with IAM roles for Backup S3 Bucket + * Setup CRDs + Cluster-level permissions + Backup Infrastructure + * Confirm Velero is installed and configured correctly + * Configure the Backup Storage Destination to Point to S3 +* Configuring - clickhouse-backup remote storage +* Backing up +* Restoring +* Appendix + * Running the Velero CLI + * Working with Velero - Backup + * Working with Velero - Restore + * Backup Architecture + +## WARNINGS + +### PLEASE READ - FOLLOW THESE INSTRUCTIONS EXACTLY + +These instructions have been tested as written. If you find they do not work for your use-case, please reach out to Arthur Support before modifying them. We cannot guarantee reliable operation if these instructions are not followed exactly as written. + +### PLEASE READ - TAKE CARE WHEN RESTORING INTO A NEW CLUSTER + +When restoring into a new cluster, you must ensure that the new cluster is unable to communicate with any services or data store in the old cluster. + +If you took a backup on cluster "Apple", and performed a restore into cluster "Banana", cluster "Banana" must point to its own RDS Instance, ClickHouse Database, and Kafka Store (note: it is ok if clusters share an S3 bucket, but not ideal). + +To ensure this, you must re-configure via the Admin Interface when restoring into a new cluster. Failure to do this **WILL CAUSE DATA CORRUPTION** on both clusters that is unrecoverable. + +### PLEASE READ - ENSURE CONSISTENCY WITH BACKUPS + +If you are either manually taking a backup, or scheduling a backup, you **MUST** take a backup of of the full platform. You **CANNOT** use a ClickHouse snapshot taken at midnight with a RDS snapshot taken at 0400 AM (or any other time). All backup operations must be performed at the same time, and when restoring, the data you are using must all belong to the same backup operation. This is to ensure data consistency across the different data stores. **IGNORING THIS WILL CAUSE DATA CORRUPTION**. + +## Overview + +The overall backup and restore process for the Arthur Platform is as follows: + +* Backup a cluster + * Take a backup of ClickHouse Data + * Take a backup of Kubernetes Deployment State and Persistent Volumes + * Enrichments infrastructure + * Model Servers + * Data Pipeline Services + * Enrichment / Delete Enrichment Workflows + * Kafka Deployment State and EBS Volumes (using EBS Snapshots) + * Take a backup of RDS Postgres +* Restore the cluster + * Restore RDS Postgres + * Update configuration and install the platform + * Restore ClickHouse Data + * Restore the Kafka Deployment State and Persistent Volumes + * Restore Enrichments infrastructure + * Restore Workflows +* Smoke Tests and Validation + +### Overview - clickhouse-backup + +The Arthur Platform stores inference data, data built from the enrichments pipeline, reference and ground truth data in ClickHouse. ClickHouse is an open-source OLAP Database which enables SQL-like query execution, replication, sharding and many additional features. + +To backup ClickHouse, the Arthur Platform uses a tool called [clickhouse-backup](https://github.com/AlexAkulov/clickhouse-backup). clickhouse-backup is a sidecar-container included on the ClickHouse pods and is responsible for taking backups, performing restores, and coordinating with remote storage (in this case S3) to store and retrieve backups. clickhouse-backup uses built-in functionality of ClickHouse to take backups and perform restores. + + +### Overview - Velero + +The Arthur Platform uses [Velero](https://velero.io/) as its Backup and Restore tool. Velero is an industry-standard, battle-tested tool for backing up Kubernetes Resources as well as Persistent Volumes. + +Arthur uses velero to backup most namespaced kubernetes resources, as well as the EBS Volume Snapshot backups for each PersistentVolumes claimed by the StatefulSets (eg: via PVCs). + +Backup data (not including EBS Volume Snapshots) is stored in an S3 bucket which is accessible via a ServiceAccount that is provisioned for the Backup and Restore agent. Backup and Restores are managed by Velero using Kubernetes Custom Resource Definitions (CRDs), which are consumed by the Velero Backup Controller and Restic Agents. + +Velero has a feature which also allows backups to be scheduled, using a cron-like configuration. It also provides `ServiceMonitors` which expose metrics via Prometheus, so that operators can monitor backup and restore status and set up alerts for when backups or restores fail. + +### Overview - Arthur (Argo)Workflows + +The Arthur Platform uses [Argo Workflows](https://argoproj.github.io/argo-workflows/) as a workflow orchestration engine for running certain jobs. Argo installs a handful of Custom Resource Definitions (CRDs) which enable the Argo Workflow services to schedule, execute and update these jobs. + +Workflows are dynamically managed, meaning that their definitions are not stored in the Arthur installer script. The Backup and Restore operation accounts for this by treating restoration of Workflows on a case-by-case basis, as follows: + +* Enrichments and Delete Enrichments workflows + * These workflows are created to create and tear-down infrastructure necessary for processing enrichments data (eg: kafka topics, pods which manage the data pipeline for enrichments, etc.) + * These workflows are idempotent and safe to recover + * Therefore, these workflows are backed up and restored just like any other Kubernetes Resource during the backup stage +* Batch workflows + * These workflows are created to manage batch jobs, which are used by clients when uploading large data files to models (inferences and/or ground truths). + * These workflows are sometimes safe to recover + * Therefore, these workflows are restored selectively based on what state they were in when the backup was taken + * Workflows for which Arthur received all of the data from the client are resumed by manually re-submitting them (this is done via an Administrative HTTP endpoint that needs to manually be called) + * Workflows for which Arthur did not receive all the data from the client will need to be re-submitted. Operators restoring the cluster will need to reach out to affected clients to communicate that their batch workflows should be re-submitted. +* Reference and Cron Workflows + * Reference Workflows are created for monitoring the upload of reference datasets to S3 + * Reference datasets that were in-flight during a backup will need to be re-uploaded with the SDK. + * Cron Workflows are scheduled workflows which perform some regular processing (eg: triggering alerts for non-batch inferences) + * Cron Workflows are meant to be run on a regular schedule. It is safe to wait for the next workflow to be triggered, and therefore, these workflows are not backed up nor restored. + +### Overview - S3 + +The Arthur Platform uses AWS S3 as object storage for storing inference data, reference data, as well as data and trained models for the enrichments pipeline. + +Arthur recommends ensuring that the AWS S3 bucket used for this storage is configured with Live Cross-Region Replication so that objects are available in the event of an AWS region outage. + +The Arthur Backup solution does not manage consistency with the S3 bucket and other backup data. +The data in S3 is only used in conjuction with data that is stored in Postgres (eg: model definitions), so it's ok if there's data in S3 that isn't represented in Postgres. +Therefore, the S3 bucket for a cluster will always reflect the most up-to-date state, regardless of when a backup was taken. + +To read more about S3 Bucket Replication, check out the AWS Documentation: +* https://docs.aws.amazon.com/AmazonS3/latest/userguide/replication.html + +## Pre-requisites + + +The following items must be configured specifically in this capacity in order to use Arthur's Backup and Restore capabilities: + +1. Arthur must be configured using external object storage, specifically, S3 +2. The access to external storage must be configured using IRSA Annotations +3. In order to use IRSA Annotations, the cluster must be deployed using Amazon EKS + +If the following are not true/possible for your deployment, please reach out to Arthur Support so we can discuss. + + + +## Installing - Velero + +The only component that needs to be installed separately from Arthur to perform backup and restores is Velero. Below, instructions are provided for setting up Velero to store backups in S3 using Secret and Access keys. + +The general overview of the installation is as follows: + +1. Create the Velero configuration + 1. Create the policy for accessing the S3 Bucket and taking EBS Snapshots and attach to an IAM User + 2. Generate the Secret and Access keys for the IAM User + 3. Create a Velero-specific credentials file +4. Install Velero +5. Confirm Velero is installed and configured correctly +6. Configure the Backup Storage Destination to Point to S3 + +### Create the Velero Configuration + +The instructions here are taken from the Velero AWS Plugin Documentation, which can be found in Option 1 here: +https://github.com/vmware-tanzu/velero-plugin-for-aws#setup + +1. Create the IAM user: + + ```bash + aws iam create-user --user-name velero + ``` + + If you'll be using Velero to backup multiple clusters with multiple S3 buckets, it may be desirable to create a unique username per cluster rather than the default `velero`. + +2. Attach policies to give `velero` the necessary permissions: + + ``` + cat > velero-policy.json <, + "AccessKeyId": + } + } + ``` + +4. Create a Velero-specific credentials file (`credentials-velero`) in your local directory: + + ```bash + [default] + aws_access_key_id= + aws_secret_access_key= + ``` + + where the access key id and secret are the values returned from the `create-access-key` request. + +### Install Velero + +To install Velero, first install the Velero CLI. Instructions for how to do this can be found on the Velero Documentation site: https://velero.io/docs/v1.10/basic-install/#install-the-cli + +Once the Velero CLI is installed, you can use this to install Velero on the cluster. Please ensure that your kubeconfig is pointing to the cluster, as this is what it used by the Velero CLI to communicate with the cluster. + +To install Velero, use the following command, ensuring that the path to the credentials file you generated in the last step is provided correctly: + +``` +velero install \ + --provider aws \ + --plugins velero/velero-plugin-for-aws:v1.6.0 \ + --bucket $BUCKET \ + --backup-location-config region=$REGION \ + --snapshot-location-config region=$REGION \ + --secret-file ./credentials-velero +``` + +### Confirm Velero is installed and configured correctly + +To confirm that Velero is installed and configured correctly: + +1. Open the Kots Admin Interface and navigate to the "Snapshots" tab +2. Click the "Check for Velero" button (see the screenshot below) + +![Check for Velero](/_static/images/velero-configuration-check.png) + +### Configure the Backup Storage Destination to Point to S3 + +The final step in configuring Velero is to configure the Backup Storage Destination to point to the S3 Bucket where the backups will be stored. + +To do this, add a new "Backup Storage Destination" in the Admin Interface and fill in the details for the S3 Bucket and for the Secret and Access keys. + +## Configuring - clickhouse-backup remote storage + +Before continuing, please ensure that your cluster is setup and configured as described in the "Pre-requisites" section above. + +Configuring clickhouse-backup to store backups in remote storage (eg: S3) can be done in the Kots Admin Interface. + +If you've performed the configuration steps as mentioned in the "Pre-requisites" section, you should see the "Enable Olap Database Backup Capabilites" option in the "Olap Database" section (see screenshot) + +![Configure Olap Backups](/_static/images/clickhouse-backup.png) + +Ensure that: + +1. The configuration that points to the bucket is correct + * The Bucket Name + * The Bucket Region +2. The ServiceAccount is the same ServiceAccount that you've configured with the IRSA Annotation (if you are not sure, enter the default value) +3. The IAM Role that you are using for the IRSA Annotation has the appropriate permissions to read/write/list from the S3 bucket + * Note - you can use the same permissions that are described in the Velero Section, just be sure to update the bucket ARN that the permissions apply to +4. The S3 Path is where you want to be storing backups + +Once you've configured clickhouse-backup, you can validate that the configuration is correct by trying to take a backup. Refer to the "Take a backup of ClickHouse Data" section below on how to do this. + +## Backing up + +Note that you can use the following script to run all of these steps together. Read the `Appendix: Running the Velero CLI` for instructions on how to run velero. + +```bash +#!/bin/bash + +set -euo pipefail +IFS=$'\n\t' + +# You need to configure this by getting the name of the storage location +# using the velero CLI +# eg: `velero backup-location get` +storage_location="Put your storage location here" + +backup_date=$(DATE +%Y-%m-%d-%H-%M-%S); +name=arthur-backup-$backup_date +echo "Creating a new backup with name $name" + +echo "Taking a backup of CH data" +kubectl create job $name-clickhouse-backup \ + --from=cronjob/clickhouse-backup-cronjob +ch_backup_jobname=$(kubectl get jobs -o name | grep "$name-clickhouse-backup") +kubectl wait $ch_backup_jobname \ + --for=condition=complete \ + --timeout=30m + +echo "Taking a backup of the enrichments infrastructure" +velero backup create $name-enrichments \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --selector='component in (kafka-mover-init-connector, model_server)' \ + --include-resources=deployments,services \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io,secrets,configmaps \ + --storage-location=$storage_location \ + --wait + +echo "Taking a backup of workflows" +velero backup create $name-workflows \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --include-resources=workflows \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io,secrets,configmaps \ + --storage-location=$storage_location \ + --wait + +echo "Taking a backup of Kafka/Kafka-ZK StatefulSets, their EBS Volumes, and related components" +velero backup create $name-stateful-sets \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --selector='app in (cp-zookeeper,cp-kafka)' \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io \ + --storage-location=$storage_location \ + --wait + +echo "Taking a backup of the RDS database" +aws rds create-db-cluster-snapshot \ + --db-cluster-snapshot-identifier $name-snapshot \ + --db-cluster-identifier RDS_DB_NAME \ + --profile AWS_PROFILE_NAME \ + --region AWS_REGION +``` + +### Take a backup of ClickHouse Data + +By default, the Arthur Platform ships with a Kubernetes CronJob which takes a ClickHouse Backup each day at midnight. + +Please see the warning `PLEASE READ - ENSURE DATA CONSISTENCY` at the top if attempting to take a manual backup. + +To take a manual backup of ClickHouse Data, you can run the following commands: + +```bash +$ kubectl get cronjobs -n arthurai +NAME SCHEDULE SUSPEND ACTIVE LAST SCHEDULE AGE +arthurai-cron-workflow-cron-job 1 0 * * * False 0 14h 2d18h +arthurai-model-health-cron-job 5 * * * * False 0 20m 2d18h +clickhouse-backup-cronjob 0 0 * * * False 0 14h 2d18h +$ kubectl create job clickhouse-backup --from=cronjob/clickhouse-backup-cronjob -n arthurai +job.batch/clickhouse-backup created +$ kubectl get jobs -n arthurai +NAME COMPLETIONS DURATION AGE +clickhouse-backup-cronjob-27735840 1/1 8m35s 14m +``` + +### Take a backup of Enrichments infrastructure and Enrichment / Delete Enrichment Workflows + +The Arthur Platform uses Velero to take a backup of the Enrichments Infrastructure, as well as the Enrichments workflows. The backup is orchestrated manually and requires running a command. + +The Enrichments infrastructure and Enrichment Workflows are orchestrated as separate backups and will require running 2 separate commands. + +To take a manual backup of the Enrichments infrastructure, run the following commands: + +```bash +$ backup_date=$(DATE +%Y-%m-%d-%H-%M-%S); +$ name=arthur-backup-$backup_date +$ velero backup create $name-enrichments \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --selector='component in (kafka-mover-init-connector, model_server)' \ + --include-resources=deployments,services \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io,secrets,configmaps \ + --storage-location=$storage_location \ + --wait +``` + +To take a manual backup of the Enrichments Workflows, run the following commands: + +```bash +$ backup_date=$(DATE +%Y-%m-%d-%H-%M-%S); +$ name=arthur-backup-$backup_date +velero backup create $name-workflows \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --include-resources=workflows \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io,secrets,configmaps \ + --storage-location=$storage_location \ + --wait +``` + +### Take a backup of Kafka Deployment State and EBS Volumes (using EBS Snapshots) + +The Arthur Platform uses Velero to take a backup of the Kafka Deployment State and EBS Volumes. The backup is orchestrated manually and requires running a command. + +To take a manual backup of Kafka, run the following commands: + +```bash +$ backup_date=$(DATE +%Y-%m-%d-%H-%M-%S); +$ name=arthur-backup-$backup_date +$ velero backup create $name-zookeeper \ + --namespace=arthurai \ + --include-namespaces=arthurai \ + --selector='app in (cp-zookeeper,cp-kafka)' \ + --exclude-resources=clusterrolebindings.rbac.authorization.k8s.io,clusterroles.rbac.authorization.k8s.io,controllerrevisions.apps,endpointslices.discovery.k8s.io,customresourcedefinitions.apiextensions.k8s.io \ + --storage-location=$storage_location \ + --wait +``` + +If you are unable to run the Velero CLI locally, you can execute it from the Velero container. See the section **Executing on the Velero Backup Controller Pod** for more details. + + +### Take a backup of RDS Postgres + +The script above provides the command line instructions for taking a backup of a RDS Database (also copied here). Please ensure that the values for the `db-cluster-identifier`, `profile` and `region` are filled in correctly. + +Note that the command is only compatible for a multi-region RDS Database. If you are using a single-region RDS Database, the command to use is `aws rds create-db-snapshot`. + +```bash +aws rds create-db-cluster-snapshot \ + --db-cluster-snapshot-identifier $name-snapshot \ + --db-cluster-identifier RDS_DB_NAME \ + --profile AWS_PROFILE_NAME \ + --region AWS_REGION +``` + +For more information, please refer to the AWS Documentation: +* Multi-region RDS instance: + * https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_CreateMultiAZDBClusterSnapshot.html + * https://awscli.amazonaws.com/v2/documentation/api/latest/reference/rds/create-db-cluster-snapshot.html +* Single-region RDS instance: + * https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_CreateSnapshot.html + * https://awscli.amazonaws.com/v2/documentation/api/latest/reference/rds/create-db-snapshot.html + +## Restoring + +### Restore the RDS Postgres + +To restore RDS Postgres, use the following resource: +https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_RestoreFromMultiAZDBClusterSnapshot.Restoring.html + +Please ensure that you correctly match the following configuration from the DB from which the snapshot was taken +* The connection port +* The VPC and Security Group IDs +* DB Subnet Group +* DB Instance Type +* Any other configuration which might be overridden + +This operation might take a while and the DB must show as Available before installing the platform. + +### Update configuration and install the platform + +**NOTE - Before completing this action, please check the following:** + +1. The Restored RDS DB Instance is showing as "Available" +2. All pods which were restored are showing as "Running" + +**NOTE - IMPORTANT -- Update configuration to point to the new DB Instance** + +It is **CRITICALLY IMPORTANT** to update your configuration to point to the newly restored DB Instance. Failure to complete this step **WILL CAUSE DATA CORRUPTION**. + +Please update the configuration in the "Meta Database" section of the Admin Interface to point to the newly restored DB instance. + +If your new cluster is routed via a different ingress URL, please also update this in the "Network" section of the configuration. + +Wait for the platform to come back online before proceeding to the next steps. All Deployments and StatefulSets should be completely stood up (eg: all Pods should be ready and "Running") and all Jobs should be "Completed". + + +### Restore ClickHouse Data + +The Arthur Platform ships with a Kubernetes CronJob that executes a ClickHouse restore that is scheduled to never run (eg: it's scheduled to run on February 31st, which is an invalid date). + +To run a ClickHouse data restore, execute the following commands: + +First, we need to get the name of the clickhouse-backup that coincides with the kafka/enrichments/workflow backups that you are restoring: + +```bash +$ kubectl get pods | grep olap +chi-olap-installation-arthur-0-0-0 2/2 Running 0 6d23h +chi-olap-installation-arthur-0-1-0 2/2 Running 0 6d23h +chi-olap-installation-arthur-0-2-0 2/2 Running 0 6d23h +olap-installation-zookeeper-0 3/3 Running 0 6d23h +olap-installation-zookeeper-1 3/3 Running 0 6d22h +olap-installation-zookeeper-2 3/3 Running 0 6d23h +olap-operator-8c867ddff-kc22x 2/2 Running 0 6d23h +$ kubectl exec chi-olap-installation-arthur-0-0-0 -c backup -- clickhouse-backup list +2022/10/04 16:03:20.255378 info SELECT value FROM `system`.`build_options` where name='VERSION_INTEGER' +2022/10/04 16:03:20.257582 info SELECT * FROM system.disks; +2022/10/04 16:03:20.267149 info SELECT count() AS is_macros_exists FROM system.tables WHERE database='system' AND name='macros' +2022/10/04 16:03:20.271359 info SELECT * FROM system.macros +chi-olap-installation-arthur-0-0-arthur-clickhouse-backup-2022-09-26-19-50-43 3.64MiB 02/10/2022 00:00:16 remote tar, regular +chi-olap-installation-arthur-0-1-arthur-clickhouse-backup-2022-09-26-19-50-43 3.64MiB 02/10/2022 00:00:16 remote tar, regular +chi-olap-installation-arthur-0-2-arthur-clickhouse-backup-2022-09-26-19-50-43 3.64MiB 02/10/2022 00:00:16 remote tar, regular +``` + +Note that from the above backup, the backup names are in the following format: +`$CLICKHOUSE_NODE_NAME-$ARTHUR_BACKUP_NAME` + +So for example, `chi-olap-installation-arthur-0-0-arthur-clickhouse-backup-2022-09-26-19-50-43` can be parsed into: +* clickhouse node name: `chi-olap-installation-arthur-0-0` +* arthur backup name: `arthur-clickhouse-backup-2022-09-26-19-50-43` + +Now we need to create the restoration job, and configure it to use the Arthur Backup Name from above: + +```bash +$ kubectl create job --from=cronjob/clickhouse-restore-cronjob -o yaml clickhouse-restore --dry-run=client --save-config > clickhouse-restore.yaml + +# update the value of the `BACKUP_NAME` environment variable in the `clickhouse-restore.yaml` file +# eg: +# - name: BACKUP_NAME +# value: "arthur-clickhouse-backup-2022-09-26-19-50-43" + +$ kubectl apply -f clickhouse-restore.yaml +job.batch/clickhouse-restore created +``` + +### Restore the Kafka Deployment State and Persistent Volumes + +The Arthur Platform restores Kafka Deployment State and PVs using Velero. + +To execute a restore, run the following commands: + +```bash +$ velero backup get -n arthurai | grep kafka +NAME STATUS ERRORS WARNINGS CREATED EXPIRES STORAGE LOCATION SELECTOR +arthur-backup-2022-09-23t11.23.25-04.00-kafka Completed 0 0 2022-09-23 11:24:37 -0400 EDT 27d default app in (cp-kafka,cp-zookeeper) +$ velero restore create \ + --from-backup "arthur-backup-2022-09-23t11.23.25-04.00-kafka" \ + --namespace arthurai \ + --restore-volumes=true \ + --existing-resource-policy=update +``` + +Velero will update the Pod Specs and point to the PVs using the EBS Volume Snapshots and restore the kubernetes resources associated with Kafka. + +### Restore Enrichments infrastructure + +The Arthur Platform uses Velero to restore the Enrichments infrastructure. + +To restore, run the following commands: + +```bash +$ velero backup get -n arthurai | grep enrichments +NAME STATUS ERRORS WARNINGS CREATED EXPIRES STORAGE LOCATION SELECTOR +arthur-backup-2022-09-23t11.23.25-04.00-enrichments Completed 0 0 2022-09-23 11:24:33 -0400 EDT 27d default component in (kafka-mover-init-connector,model_server) +$ velero restore create \ + --from-backup "arthur-backup-2022-09-23t11.23.25-04.00-enrichments" \ + --namespace arthurai +``` + +### Restore Workflows + +Restoring workflows is a 2-step process: + +1. Restore the workflows from the Velero backup +2. Restore Batch Workflows which are recoverable using an Arthur Admin Endpoint + +To restore workflows using the Velero backup, run the following commands: + +```bash +$ velero backup get -n arthurai | grep workflows +NAME STATUS ERRORS WARNINGS CREATED EXPIRES STORAGE LOCATION SELECTOR +arthur-backup-2022-09-23t11.23.25-04.00-workflows Completed 0 0 2022-09-23 11:24:35 -0400 EDT 27d default +$ velero restore create \ + --from-backup "arthur-backup-2022-09-23t11.23.25-04.00-workflows" \ + --namespace arthurai +``` + +To restore Batch Workflows, run the following comamnds. + +In one terminal window, port-forward to the dataset-service: + +```bash +$ kubectl get pods | grep dataset-service +arthurai-dataset-service-69dd979d8c-72t7j 1/1 Running 0 2d17h +$ kubectl port-forward -n arthurai arthurai-dataset-service-69dd979d8c-72t7j 7899 +``` + +Then, in another terminal window, run the following commands: + +```bash +$ curl -k -XPOST https://localhost:7899/api/v1/workflows/batch/recover +{"message":"success"} +``` + +### Smoke Tests and Validation + +The restore should now be complete. All data should be restored and in a consistent state as it was from when the backup was taken. Any data sent during or after the backup will need to be re-sent. Perform any validation/smoke-tests to ensure that the platform is operating. + +## Appendix + +### Running the Velero CLI + +Velero provides a Command-Line Interface (CLI) for taking backups and performing restores. The command line interface can be installed locally, or it can be invoked by `kubectl exec` on the Velero Backup Controller pod. + +#### Local Installation + +Read through the Velero Documentation for how to install velero on your platform: +https://velero.io/docs/v1.9/basic-install/#install-the-cli + +Velero uses your KUBECONFIG file to connect to the cluster. + +``` +$ velero --help +Velero is a tool for managing disaster recovery, specifically for Kubernetes +cluster resources. It provides a simple, configurable, and operationally robust +way to back up your application state and associated data. + +If you're familiar with kubectl, Velero supports a similar model, allowing you to +execute commands such as 'velero get backup' and 'velero create schedule'. The same +operations can also be performed as 'velero backup get' and 'velero schedule create'. + +Usage: + velero [command] + +Available Commands: + backup Work with backups + backup-location Work with backup storage locations + bug Report a Velero bug + client Velero client related commands + completion Generate completion script + create Create velero resources + debug Generate debug bundle + delete Delete velero resources + describe Describe velero resources + get Get velero resources + help Help about any command + install Install Velero + plugin Work with plugins + restic Work with restic + restore Work with restores + schedule Work with schedules + snapshot-location Work with snapshot locations + uninstall Uninstall Velero + version Print the velero version and associated image + +Flags: + --add_dir_header If true, adds the file directory to the header + --alsologtostderr log to standard error as well as files + --colorized optionalBool Show colored output in TTY. Overrides 'colorized' value from $HOME/.config/velero/config.json if present. Enabled by default + --features stringArray Comma-separated list of features to enable for this Velero process. Combines with values from $HOME/.config/velero/config.json if present + -h, --help help for velero + --kubeconfig string Path to the kubeconfig file to use to talk to the Kubernetes apiserver. If unset, try the environment variable KUBECONFIG, as well as in-cluster configuration + --kubecontext string The context to use to talk to the Kubernetes apiserver. If unset defaults to whatever your current-context is (kubectl config current-context) + --log_backtrace_at traceLocation when logging hits line file:N, emit a stack trace (default :0) + --log_dir string If non-empty, write log files in this directory + --log_file string If non-empty, use this log file + --log_file_max_size uint Defines the maximum size a log file can grow to. Unit is megabytes. If the value is 0, the maximum file size is unlimited. (default 1800) + --logtostderr log to standard error instead of files (default true) + -n, --namespace string The namespace in which Velero should operate (default "velero") + --skip_headers If true, avoid header prefixes in the log messages + --skip_log_headers If true, avoid headers when opening log files + --stderrthreshold severity logs at or above this threshold go to stderr (default 2) + -v, --v Level number for the log level verbosity + --vmodule moduleSpec comma-separated list of pattern=N settings for file-filtered logging + +Use "velero [command] --help" for more information about a command. +``` + +#### Executing on the Velero Backup Controller Pod + +``` +$ kubectl exec velero-699dc869d4-r24bh -c velero -- /velero +Velero is a tool for managing disaster recovery, specifically for Kubernetes +cluster resources. It provides a simple, configurable, and operationally robust +way to back up your application state and associated data. + +If you're familiar with kubectl, Velero supports a similar model, allowing you to +execute commands such as 'velero get backup' and 'velero create schedule'. The same +operations can also be performed as 'velero backup get' and 'velero schedule create'. + +Usage: + velero [command] + +Available Commands: + backup Work with backups + backup-location Work with backup storage locations + bug Report a Velero bug + client Velero client related commands + completion Generate completion script + create Create velero resources + debug Generate debug bundle + delete Delete velero resources + describe Describe velero resources + get Get velero resources + help Help about any command + install Install Velero + plugin Work with plugins + restic Work with restic + restore Work with restores + schedule Work with schedules + snapshot-location Work with snapshot locations + uninstall Uninstall Velero + version Print the velero version and associated image + +Flags: + --add_dir_header If true, adds the file directory to the header + --alsologtostderr log to standard error as well as files + --colorized optionalBool Show colored output in TTY. Overrides 'colorized' value from $HOME/.config/velero/config.json if present. Enabled by default + --features stringArray Comma-separated list of features to enable for this Velero process. Combines with values from $HOME/.config/velero/config.json if present + -h, --help help for velero + --kubeconfig string Path to the kubeconfig file to use to talk to the Kubernetes apiserver. If unset, try the environment variable KUBECONFIG, as well as in-cluster configuration + --kubecontext string The context to use to talk to the Kubernetes apiserver. If unset defaults to whatever your current-context is (kubectl config current-context) + --log_backtrace_at traceLocation when logging hits line file:N, emit a stack trace (default :0) + --log_dir string If non-empty, write log files in this directory + --log_file string If non-empty, use this log file + --log_file_max_size uint Defines the maximum size a log file can grow to. Unit is megabytes. If the value is 0, the maximum file size is unlimited. (default 1800) + --logtostderr log to standard error instead of files (default true) + -n, --namespace string The namespace in which Velero should operate (default "arthurai") + --skip_headers If true, avoid header prefixes in the log messages + --skip_log_headers If true, avoid headers when opening log files + --stderrthreshold severity logs at or above this threshold go to stderr (default 2) + -v, --v Level number for the log level verbosity + --vmodule moduleSpec comma-separated list of pattern=N settings for file-filtered logging + +Use "velero [command] --help" for more information about a command. +``` + +### Working with Velero - Backup + +To take a backup of Arthur, you would invoke the CLI as follows. + +```bash +$ velero backup create arthur-backup-$(date -Iseconds | tr ":" "." | tr "T" "t") \ + --namespace=arthurai \ + --include-namespaces=arthurai +``` + +The command above will create a Velero Backup Resource named `arthur-backup-`, which you can check using the Velero CLI: + +```bash +$ velero backup get -n arthurai +NAME STATUS ERRORS WARNINGS CREATED EXPIRES STORAGE LOCATION SELECTOR +arthur-backup-2022-08-25t09.59.35-04.00 Completed 0 0 2022-08-25 09:59:35 -0400 EDT 28d default +arthur-backup-2022-08-26t10.37.52-04.00 InProgress 0 0 2022-08-26 10:37:52 -0400 EDT 29d default +``` + +For debugging a backup, you can access the backup's logs using the Velero CLI: + +```bash +$ velero backup logs arthur-backup-2022-08-25t09.59.35-04.00 -n arthurai | head +time="2022-08-25T13:59:35Z" level=info msg="Setting up backup temp file" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/controller/backup_controller.go:587" +time="2022-08-25T13:59:35Z" level=info msg="Setting up plugin manager" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/controller/backup_controller.go:594" +time="2022-08-25T13:59:35Z" level=info msg="Getting backup item actions" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/controller/backup_controller.go:598" +time="2022-08-25T13:59:35Z" level=info msg="Setting up backup store to check for backup existence" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/controller/backup_controller.go:608" +time="2022-08-25T13:59:36Z" level=info msg="Writing backup version file" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:192" +time="2022-08-25T13:59:36Z" level=info msg="Including namespaces: arthurai" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:198" +time="2022-08-25T13:59:36Z" level=info msg="Excluding namespaces: " backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:199" +time="2022-08-25T13:59:36Z" level=info msg="Including resources: *" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:202" +time="2022-08-25T13:59:36Z" level=info msg="Excluding resources: " backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:203" +time="2022-08-25T13:59:36Z" level=info msg="Backing up all pod volumes using Restic: false" backup=arthurai/arthur-backup-2022-08-25t09.59.35-04.00 logSource="pkg/backup/backup.go:204" + + +``` + +Finally, you can get an overview of the backup using the Velero CLI: + +```bash +$ velero backup describe arthur-backup-2022-08-25t09.59.35-04.00 -n arthurai +Name: arthur-backup-2022-08-25t09.59.35-04.00 +Namespace: arthurai +Labels: velero.io/storage-location=default +Annotations: velero.io/source-cluster-k8s-gitversion=v1.21.14-eks-18ef993 + velero.io/source-cluster-k8s-major-version=1 + velero.io/source-cluster-k8s-minor-version=21+ + +Phase: Completed + +Errors: 0 +Warnings: 0 + +Namespaces: + Included: arthurai + Excluded: + +Resources: + Included: * + Excluded: + Cluster-scoped: auto + +Label selector: + +Storage Location: default + +Velero-Native Snapshot PVs: auto + +TTL: 720h0m0s + +Hooks: + +Backup Format Version: 1.1.0 +szExpiration: 2022-09-24 09:59:35 -0400 EDT + +Total items to be backed up: 654 +Items backed up: 654 + +Velero-Native Snapshots: 3 of 3 snapshots completed successfully (specify --details for more information) + +Restic Backups (specify --details for more information): + Completed: 23 +``` + + +### Working with Velero - Restore + +Similar to backup, restore happens using the Velero Cli. A restore takes a Backup object and then executes the restore procedure. + +You can execute a restore with the following Velero CLI command: + +```bash +$ velero restore create \ + --from-backup arthur-backup-2022-08-25t09.59.35-04.00 \ + --namespace arthurai \ + --restore-volumes=true +``` + +Just like with the Backup, Velero will create a Restore Velero Resource, which you can inspect with the Velero CLI: + +```bash +$ velero restore get -n arthurai +NAME BACKUP STATUS STARTED COMPLETED ERRORS WARNINGS CREATED SELECTOR +arthur-backup-2022-08-26t10.37.52-04.00-20220826110520 arthur-backup-2022-08-26t10.37.52-04.00 Completed 2022-08-26 11:06:16 -0400 EDT 2022-08-26 11:08:00 -0400 EDT 0 35 2022-08-26 11:05:21 -0400 EDT +``` diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/index.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..57a1a83e05cbcaccd31446866c68285c4f6b7fe1 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/index.md.txt @@ -0,0 +1,31 @@ +# Ongoing Maintenance + +This section covers information for platform administrators responsible for ongoing maintenance of the Arthur platform. + +## {doc}`audit_log` +This page shows how to audit log of all calls to sensitive Arthur endpoints. + +## {doc}`Administration ` +This page shows how handle administration settings for managing your Arthur account. + +## {doc}`organizations_and_users` +This page shows how to manage and create Arthur organizations and +users. + +## {doc}`backup` +This page shows how to use Arthur's managed backup and restore capability. + +## {doc}`upgrade` +This page shows how to upgrade Arthur platform components. +*** + +```{toctree} +:maxdepth: 2 +:hidden: + +Audit Log +Administration +Organizations and Users +Backup and Restore +Upgrade +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/organizations_and_users.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/organizations_and_users.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..08db017065d719dca9689e36a91421265e2b394a --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/organizations_and_users.md.txt @@ -0,0 +1,182 @@ +# Organizations and Users + +By default, a new organization, "My Organization" is created by the installer for convenience. You can also create new +organizations using the API with the `superadmin` user. + +### Log in with superadmin credentials + +The first thing you will need is a `superadmin` authorization token. To obtain this, you will need to make a `POST` +request to your organization's `/login` endpoint with the password set in the Admin Console Config page. + +``` +POST /login +``` +```json +{ + "login": "superadmin", + "password": "" +} +``` + +The response will look like this: + +```json +{ + "id": "ed1dcb56-352a-4130-8f52-1fd1225196b1", + "first_name": "Super", + "last_name": "Admin", + "email": "superadmin@arthur.ai", + "username": "superadmin", + "roles": null, + "active": true, + "show_intro_sequence": true, + "help_mode_enabled": false, + "created_at": "2021-08-09T19:57:44.92047Z" +} +``` + +The response will also include a `set-cookie` HTTP header with an authorization token.` Copy the authorization token value and use it in subsequent +requests as your auth token. + +``` +set-cookie: Authorization=; Path=/; Expires=Mon, 30 Aug 2021 16:51:07 GMT; Secure; +``` + +#### cURL example + +```bash +curl --location --request POST 'https:///api/v3/login' --header 'Content-Type: application/json' --data-raw '{ "login": "superadmin", "password": "" }' -v +``` + +### Create a New Organization +To create a new organization, you will need to make a `POST` request to `/organizations` with the body specifying +the name. Ensure you are using a super admin authentication token to make this request. + +``` +POST /organizations +``` +```json +{ + "name": "my-new-organization" +} +``` + +The response will look like this: + +```json +{ + "id": "38faff8b-4edf-44c5-b103-aeca4ea71110", + "name": "my-new-organization", + "plan": "enterprise", + "created_at": "2021-08-18T19:51:22.291504554Z" +} +``` + +Remember to save the `id`; you will need this to add users to your organization. + +#### cURL Example + +```bash +curl --location --request POST '/api/v3/organizations' --header 'Content-Type: application/json' --header 'Authorization: ' --data-raw '{ "name": "my-new-organization" }' -v +``` + +### Create The First User in an Organization + +To create a new user in the new organization, you will need to make a `POST` request to +`/users?organization_id=` using a super admin authentication token. You can set the role of the new user to `Administrator`, +`Model Owner`, or `User`. Refer to the [authorization page](../access-control-overview/standard_access_control) for the description of the roles. + +``` +POST /users?organization_id= +``` +```json +{ + "username": "newuser", + "email": "newuser@email.com", + "password": "G00dP@$$w0rd!", + "first_name": "New", + "last_name": "User", + "roles": [ + "Administrator" + ], + "alert_notifications_enabled": true +} +``` + +The response will look like this. + +```json +{ + "id": "b6554927-9ac4-4531-bf76-fe640b8223b7", + "first_name": "New", + "last_name": "User", + "email": "newuser@email.com", + "username": "newuser", + "roles": null, + "active": true, + "show_intro_sequence": true, + "help_mode_enabled": true, + "created_at": "2021-08-18T20:20:18.535137592Z" +} +``` + +You can now log in to the dashboard as this user. + +#### cURL Example +This action can be performed as either super administrator or organization administrator. +If you'd like to use an organization administrator, repeat the `/login` API call performed earlier with the credentials for that user and save the returned authorization token. + +```bash +curl --location --request POST 'https:///api/v3/users?organization_id=' --header 'Content-Type: application/json' --header 'Authorization: ' --data-raw '{ "username": "", "email": "", "password": "", "first_name": "", "last_name": "", "roles": [ "Administrator" ], "alert_notifications_enabled": true }' +``` + +### Adding Additional Users + +Although you can continue to create users through the API, it is generally easier to create an `Administrator` user +and then invite additional users from the UI. To add additional users this way, log in to Arthur AI with an `Administrator` +user on a web browser and follow these steps: + +1. In the top right corner, you will see a series of icons. Click on the Organization icon that looks like a tree with three nodes. + + ![My Organization Panel](/_static/images/platform/my_organization_panel.png "My Organization Panel") + +2. You will see a dropdown menu. Click on `Manage Members` +3. Under the heading, `Invite Members`, you can type in the email address of the person you wish to invite. + That person will receive instructions for how to create a user in the organization via email. + + ![Invite Members Section](/_static/images/platform/invite_members_section.png "Invite Members Section") + +4. Once the new user follows the emailed instructions, they will be able to log in with their newly created + username and password. You will then be able to view that new user on this `Manage Members` page. +5. As an `Administrator`, you can continue to use this page to manage users and roles. + + +### Adding Existing Users To Existing Organizations via API: +To add an existing user to an existing organization create a `PATCH` request to `/organizations//users`. +Supplying in the body a json object defining the role (`Administrator`, +`Model Owner`, or `User`) you want to add the user with. Any attributes other than roles that are supplied in the body +will effect the user across all organizations that user is a part of. + +``` +PATCH /organizations//users +``` +```json +[ + { + "user_id": "b6554927-9ac4-4531-bf76-fe640b8223b7", + "role": "Model Owner" + } , + { + "user_id": "b6554927-9ac4-4531-bf76-fe640b8223b7", + "role": "Model Owner" + } +] +``` + +The response will look like this. + +```json +{ + "updated_user_count": 10 +} +``` diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/post_install.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/post_install.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ebe5602cc5e09b3ba0c0fd3a9a164347e86ab228 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/post_install.md.txt @@ -0,0 +1,33 @@ +# Post Installation Steps + +By default, a new organization, "My Organization" is created by the installer for convenience. You can also create new +organizations using the API with the `superadmin` user. Full instructions for creating new users and organizations can +be found {doc}`here `. + +To access the UI for the default organization dashboard, visit `https://your_arthur_domain` from your Web browser. +Login with `admin` username and `SuperSecret` password. Make sure to change the password as soon as possible. + +To get started with onboarding your models, refer to the [Quickstart](../../user-guide/arthur_quickstart) guide. + +## Admin Console +The Admin Console can be made available via the ingress controller on port 443 by creating a subdomain DNS record that starts with `admin.` +(e.g. admin.arthur.mydomain.com). For VM install, this eliminates the port 8800 egress requirement on the firewall. + +We recommend that you rotate your Admin Console password often. You can reset the password using this command: +```shell +kubectl kots reset-password -n +``` + +## Update Admin password for Embedded Postgres + +The 'postgres' admin user is used to manage the embedded Postgres database. If you would like to update the password for this admin user, you can execute the following commands on the primary database pod: +```shell +kubectl exec -it database-master-0 -- psql -U postgres +Password for user postgres: +psql (11.13) +Type "help" for help. + +postgres=# ALTER ROLE postgres WITH PASSWORD ''; +postgres=# \q +$ +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/ongoing-maintenance/upgrade.md.txt b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/upgrade.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7349ef1d35649f2b4416db27a3e7cffe44900750 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/ongoing-maintenance/upgrade.md.txt @@ -0,0 +1,8 @@ +# Upgrading + +Arthur's platform installer leverages an open source solution called [Kubernetes Off-The-Shelf (KOTS)](https://github.com/replicatedhq/kots). +Please refer to the below links for upgrading the platform components. + +* [Upgrading the platform application](https://kots.io/kotsadm/updating/updating-kots-apps/) +* [Upgrading the Admin Console](https://kots.io/kotsadm/updating/updating-admin-console/) +* [Upgrading the embedded Kubernetes cluster for VM install](https://kots.io/kotsadm/updating/updating-embedded-cluster/) diff --git a/files/arthur-docs-markdown/platform-management/reference/config_dump.md.txt b/files/arthur-docs-markdown/platform-management/reference/config_dump.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..78f138a72aa5b0c1fdd84a4b1fa3985667cd4740 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/config_dump.md.txt @@ -0,0 +1,11 @@ +# Exporting Platform Configurations + +After a successful installation of the Arthur platform, you can download the configuration that was used as a `.yaml` file by following the below steps: + +1. Navigate to the Admin Console and login. +![.png image](/_static/images/platform/admin-console-login.png) +2. Click on the **"View Files"** tab. +![.png image](/_static/images/platform/admin-console-view-files.png) +3. Go to **upstream → userdata** and click on `config.yaml` file. +![.png image](/_static/images/platform/admin-console-config-yaml.png) +4. Copy the contents of that file and save it for future use (or check-in to source control). \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/reference/config_template.md.txt b/files/arthur-docs-markdown/platform-management/reference/config_template.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..eb7f7105e872c5f42d53741684a30e866e7e80b9 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/config_template.md.txt @@ -0,0 +1,371 @@ +# Configuration File Template + +The Configuration template for Arthur version `3.2.1` is below: + +```yaml +apiVersion: kots.io/v1beta1 +kind: ConfigValues +metadata: + creationTimestamp: null + name: arthur +spec: + values: + IAM_permission_type: + default: access_keys + advanced_cache_options: + default: "0" + advanced_messaging_connect_cpu_limits: + default: "2" + advanced_messaging_connect_cpu_limits_not_validate: {} + advanced_messaging_connect_cpu_requests: + default: "1" + advanced_messaging_connect_cpu_requests_not_validate: {} + advanced_messaging_connect_heap_options: + default: -Xms1g -Xmx3g + advanced_messaging_connect_memory_limits: + default: 4Gi + advanced_messaging_connect_memory_limits_not_validate: {} + advanced_messaging_connect_memory_requests: + default: 2Gi + advanced_messaging_connect_memory_requests_not_validate: {} + advanced_olap_options: + default: "0" + advanced_other: + default: "0" + value: "1" + alert_service_update_rule_metrics: + default: "0" + api_token_ttl: + default: "24" + arthur_user_id: + default: "1000" + audit_log_event_bridge_bus_name: {} + audit_log_event_bridge_bus_region: {} + audit_log_event_bridge_detail_type: + default: events.arthur.ai + audit_log_event_bridge_source: + default: arthur-audit-log + audit_log_sink_destination: + default: none + batch_workflow_parallelism: + default: "120" + beta_ui: + default: "0" + beta_ui_alternate_site: + default: "0" + beta_ui_hostname: {} + bootstrap_job_backoff_limit: + default: "100" + bootstrap_job_ttl: + default: "86400" + cache_cpu_limits: {} + cache_cpu_limits_not_validate: {} + cache_cpu_requests: {} + cache_cpu_requests_not_validate: {} + cache_memory_limits: {} + cache_memory_limits_not_validate: {} + cache_memory_requests: {} + cache_memory_requests_not_validate: {} + cache_password: + default: SuperSecret + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + cache_replicas: + default: "0" + cicd_credentials: + default: "0" + cluster_nodes: + # Only Relevant for "fixed" cluster sizes. Enter the number of nodes in the cluster. This number cannot be decreased from the current value unless it's greater than `6`. + default: "1" + value: "3" + config_job_and_workflow_retention: + default: "0" + database_admin_password: + default: SuperSecret + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + database_hostname: + # Leave the default configuration to use the embedded database. If you would like to use an external Postgres instance, provide the hostname here and follow this guide: https://docs.arthur.ai/platform-management/installation/externalize_postgres.html. + default: database-primary + database_password: + default: SuperSecret + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + database_port: + value: "5432" + database_ssl_mode: + # This option allows you to enable SSL communication between services and the postgres database. See https://www.postgresql.org/docs/10/libpq-ssl.html for full descriptions of each option. By default, the postgres database has ssl disabled. + default: disable + database_username: + default: arthurai + default_messaging_partition_count: + default: "3" + value: "1" + disable_ssl_redirect_on_ingress: + default: "0" + email_selection: + default: none + enable_audit_log: + default: "0" + enable_olap_backup: + default: '"0"' + enable_olap_backup_user: + default: "0" + enable_password_rotation_cache: + default: "0" + enable_password_rotation_olap: + default: "0" + existing_database_primary_pvc: {} + existing_or_vm: + default: existing_cluster + fixed_or_autoscale: + # The `fixed` mode is recommended for clusters with a fixed number of nodes. The `autoscale` mode is used for clusters that can autoscale and automatically expand their node count. + value: fixed + full_name_override: + default: arthurai + global_identity_provider: + default: none + global_model_limit_Count: + default: "500" + global_model_limits: + default: "0" + global_workflow_parallelism: + default: "150" + http_proxy: {} # Relevant if you are using Explainability and your organization is behind a proxy server. If PIP and/or Conda need to route through the proxy server to pull down public packages this will set the environment variable HTTP_PROXY to the supplied value. Ex. http://sysproxy.my-company.com:port + http_proxy_user: {} + https_proxy: {} + https_proxy_user: {} + ingestion_service_cpu_limits: {} + ingestion_service_cpu_limits_not_validate: {} + ingestion_service_cpu_requests: {} + ingestion_service_cpu_requests_not_validate: {} + ingestion_service_memory_limits: {} + ingestion_service_memory_limits_not_validate: {} + ingestion_service_memory_requests: {} + ingestion_service_memory_requests_not_validate: {} + ingress_ambassador_enabled: + default: "false" + ingress_class: + default: nginx + ingress_hostname: + value: arthur.mydomain.ai + ingress_namespace_label_key: + value: name + ingress_namespace_label_value: + value: ingress-system + ingress_nginx_additional_hostname: + value: "" + irsa_annotations: {} + irsa_annotations_user: + default: | + eks.amazonaws.com/role-arn: arn:aws:iam::111122223333:role/my-role + k8_storageclass: + # Provide Kubernetes StorageClass profile. Use 'gp2' for Amazon EKS, 'default' if you're using embedded Kubernetes provided by the installer + value: default + kafka_ecosystem_common_replication_calc: + default: "1" + max_arthur_replicas: + default: "1" + max_messaging_partition_count: + default: "3" + max_model_server_replicas: + default: "2" + messaging_cpu_limit: + default: "1" + messaging_heap: + default: -Xmx2G -Xms1G + messaging_memory_limit_and_request: + default: 2560Mi + messaging_rack_aware_enabled: + default: "0" + messaging_rack_label: + default: topology.kubernetes.io/zone + messaging_replicas: + default: "3" + messaging_sa_create: + default: "0" + messaging_sa_fullnameoverride: {} + messaging_zookeeper_timeout: + default: "20000" + meta_replicas: + default: "0" + metric_service_update_default_metrics: + default: "0" + min_arthur_replicas: + default: "1" + model_servers_always_on: + # For use with what-if and on-demand explainability. See https://docs.arthur.ai/user-guide/explainability.html If set to "true", then on-demand and what-if explanations are available, but uses additional cluster resources, 1 CPU and 1 GB memory per model with explainability enabled. If set to "false", on-demand and what-if explanations are unavailable, but less cluster usage when there is no data being sent. Regardless of the setting here, streaming explainability will be available if enabled. This only effects what-if and on-demand explanations. + default: "true" + network_policy_enabled: + default: "0" + no_proxy: {} # Relevant if you are using Explainability and your organization is behind a proxy server. If PIP and/or Conda need to route through the proxy server to pull down public packages this will set the environment variable NO_PROXY to the supplied value. Ex. localhost,127.0.0.1,.my-company.com + no_proxy_user: {} + number_of_olap_backups_to_keep: + default: "7" + oidc_identity_provider_config_yaml: {} + oidc_identity_provider_config_yaml_user: {} + olap_backup_s3_bucket: + default: arthurai + olap_backup_s3_bucket_region: + default: us-east-1 + olap_backup_s3_endpoint: + default: s3.us-east-1.amazonaws.com + olap_backup_s3_path: + default: olap_backups + olap_backup_service_account: + default: arthurai-arthurai + olap_cpu_limits: {} + olap_cpu_limits_not_validate: {} + olap_cpu_requests: + default: 1000m + olap_cpu_requests_not_validate: {} + olap_database_operator_password: + # The OLAP database is installed along with a Kubernetes Operator to manage it. This operator needs credentials to access the database. We recommend overwriting the default password below. + default: 5ugYLDJ2uLhRdEgz5t + value: ch/0gntnboTNbQpxmzx4GuPCRnjqSNwTpOT6FwgQ9q4iY7CHiQLeFQ3snnZgxYnFt4gSyInce3KhYiMR7eebBtGbe5sIuY/aBPAySrSjExfO+1VYPBp176bP+zQ= + olap_database_user_password: + # Password used internally in our application to query the olap database, currently only supports alpha-numeric characters. + default: eQ3iBo8UGh5zqJKQWuEEySrR + value: ch/0gntnboTNbQppnGJgGvCjSmPlS/l8orO+UggQ/rstcryCj2r/GRXR8UNr+u3plPIj+uLMdXGGFiRtko6pTsClBoQkoeLXqDVr1jeqsThCZI/bTfovlA== + olap_memory_limits: {} + olap_memory_limits_not_validate: {} + olap_memory_requests: + default: 1Gi + olap_memory_requests_not_validate: {} + olap_node_label_key: {} + olap_node_label_value: {} + olap_replicas: + default: "1" + olap_zookeeper_cpu_limits: {} + olap_zookeeper_cpu_limits_not_validate: {} + olap_zookeeper_cpu_requests: + default: 500m + olap_zookeeper_cpu_requests_not_validate: {} + olap_zookeeper_heap_options: + default: -Xms4G -Xmx4G + olap_zookeeper_memory_limits: {} + olap_zookeeper_memory_limits_not_validate: {} + olap_zookeeper_memory_requests: + default: 1Gi + olap_zookeeper_memory_requests_not_validate: {} + password_rotation_cron_schedule: + default: 0 0 1 */6 * + pending_batch_workflows_limit: + default: "100" + prometheus_host: + # Leave the default configuration if you're using the embedded K8s. Provide your Prometheus hostname if you're running your own K8s. + default: http://kube-prometheus-stack-prometheus.monitoring.svc.cluster.local + prometheus_labels: + # If your prometheus installation requires labels to identify ServiceMonitors and PrometheusRules, add them here. They should be in yaml format just as you would specify inside the "metadata.labels" block. Do not indent. + default: | + prometheus: monitor + app: prometheus + prometheus_namespace: + default: monitoring + prometheus_port: + # Leave the default configuration if you're using the embedded K8s. Provide your Prometheus hostname if you're running your own K8s. + default: "9090" + pypi_registry_conda: {} # This is set as a channel in the '.condarc' file. Do not include 'https://' prefix (e.g. repository.arthur.ai/repository/conda-proxy/main). + pypi_registry_conda_user: {} + pypi_registry_index: {} # This maps to the 'index key' in the 'pip.conf' file. Do not include 'https://' prefix (e.g repository.arthur.ai/repository/pypi-virtual/pypi). + pypi_registry_index_url: {} # This maps to the 'index-url' key in the 'pip.conf' file. Do not include 'https://' prefix (e.g. repository.arthur.ai/repository/pypi-virtual/simple). + pypi_registry_index_url_user: {} + pypi_registry_index_user: {} + pypi_registry_password: + default: bO4Mxhdaevso/029YtUgz98Wk7qPcxEpa1P/uVqG4cy4UY1B3+YN5Q== + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + pypi_registry_password_user: + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + pypi_registry_username: {} + pypi_registry_username_user: {} + raw_anaconda_config: {} + raw_anaconda_config_user: {} + raw_pypi_config: {} + raw_pypi_config_user: {} + rbac_privileges: + # Change to "cluster_scope" to install CRDs too + default: namespace_scope + run_as_root: + default: "0" + value: "0" + s3_access_key_id: + default: access_key + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + s3_access_key_id_user: + default: access_key + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + s3_bucket: + default: arthurai + s3_bucket_user: + default: arthurai + s3_region: + default: us-east-1 + s3_region_user: + default: us-east-1 + s3_secret_access_key: + default: secret_key + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + s3_secret_access_key_user: + default: secret_key + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + s3_url: + default: http://minio:9000 + s3_url_user: + default: http://minio:9000 + saml_identity_provider_config_yaml: {} + saml_identity_provider_config_yaml_user: {} + secondary_token_validation_key: + value: Aj3ziCI/YcnTT3QR3WAtMNDNEzzqTa8W9iJCoHjNFMteiO6lrcnUKw== + ses_region: {} + ses_role: {} + show_advanced_arthur_microservice_options: + default: "0" + show_advanced_messaging: + default: "0" + value: "1" + show_hidden_variables: + default: "0" + value: "0" + show_token_signing_and_validation_options: + default: "0" + signing_cert: {} + signing_cert_user: {} + signing_private_key: {} + signing_private_key_user: {} + single_or_ha: + # The `single` configuration is a minimal deployment suitable for non-production environments. For production deployment, select `ha`. + value: single + smtp_from: {} # Provide the email address to send alerts from (e.g. alerts@arthur.ai) + smtp_host: {} # Provide the address of the SMTP server (e.g. smtp.arthur.ai) + smtp_password: + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + smtp_port: {} + smtp_user: {} + superadmin_email: + default: superadmin@myorg.com + superadmin_firstname: + default: Super + superadmin_lastname: + default: Admin + superadmin_password: + default: SuperSecret + value: VwC3tnE9cpzObSxIhTx9U/34Ky+mA6p8veb9bCk+iqcAEaOarGzGEFf7ozoGxO3m05QY5YTuIx3ezMI694TUX0gj7RHSyHoK + superadmin_username: + value: superadmin + token_signing_primary_key: + value: YSDFzjg5I83KMBJ+wHQmU/ejDQ7tTthIpaDcCRM+iqcDTofiul7DZzTblFkb0e2U0+UJ74TuIx28oGnxPM+pkmKlc1yx2uvj + use_external_blob_storage: + # Select "Yes" if and only if you are supplying your own S3 compatible storage, otherwise select "No" to use the embedded blob storage. + default: "no" + use_external_postgres: + default: "no" + use_raw_python_repository_configs: + # The PyPi registry section is only relevant when using the explainability enrichment (https://docs.arthur.ai/user-guide/enrichments.html#explainability). + # Provide your private PyPi registry if you have an airgapped enrivonment or your model requirements file includes packages only hosted in a private repository. + # Leaving this section blank will cause the public PyPi to be used. If the public PyPi is inaccessible from the cluster, the explainability feature will not work. + default: "no" + use_smtp: + default: "0" + workflow_ttl_seconds: + default: "3600" + workflow_ttl_seconds_after_success: + default: "60" +status: {} +``` diff --git a/files/arthur-docs-markdown/platform-management/reference/index.md.txt b/files/arthur-docs-markdown/platform-management/reference/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..687378f342e4b864fd05e9931fa31003e7053f4c --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/index.md.txt @@ -0,0 +1,32 @@ +(reference)= +# Reference + +This section includes reference files that may be required for administrating the Arthur platform. + +## {doc}`config_template` +This template contains a standardized template for configuring KOTS (Kubernetes-off-the-shelf). + +## {doc}`config_dump` +This page shows the process for downloading the current configuration used by Arthur system. + +## {doc}`permissions_set` +This table shows the read/write permissions for various touch-points in the Arthur system. + +## {doc}`permissions_by_standard_roles` +This table shows the permissions available to each possible pre-defined standard role of an Arthur user within an organization. + +## {doc}`permissions_by_endpoint` +This table shows the permissions available to each query endpoint. + +*** + +```{toctree} +:maxdepth: 2 +:hidden: + +Configuration Template +Exporting Platform Configurations +Permissions Set +Permissions by Standard Roles +Permissions by Endpoint +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/reference/permissions_by_endpoint.md.txt b/files/arthur-docs-markdown/platform-management/reference/permissions_by_endpoint.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..49c202991ba927a194597082841166b3ed55bf07 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/permissions_by_endpoint.md.txt @@ -0,0 +1,135 @@ +## Arthur Permissions by Endpoint +For more details on the expected schema for each endpoint, see [Authorization API documenation](../../../api-documentation/v3-api-docs.html#tag/authorization). If an endpoint is not listed here, there is no authorization restriction on that endpoint and all authenticated users should be able to access it. + +For more details on the expected schema for each endpoint, +see [Authorization API documenation](../../api-documentation/v3-api-docs.html#tag/authorization). If an endpoint is not +listed here, there is no authorization restriction on that endpoint and all authenticated users should be able to access +it. + +### Org, User, and Authorization Related Permissions + +| Permission | Endpoint | REST | Resource in System | Action | +|----------------------------------------------------------|------------------------------------------------------------------------------|--------|--------------------------------------|---------| +| Get all organizations | /organizations | GET | organization_global | read | +| Create an organization | /organizations | POST | organization_global | write | +| Get an organization | /organizations/{organization_id} | GET | organization | read | +| Delete an organization | /organizations/{organization_id} | DELETE | organization | delete | +| Add users to an organization | /organizations/{organization_id}/users | PATCH | user | write | +| Create user | /users | POST | user | write | +| Get all users | /users | GET | user | read | +| Get current user | /users/me | GET | N/A | N/A | +| Update current user | /users/me | PATCH | N/A | N/A | +| Get user | /users/{user_id} | GET | user | read | +| Update user | /users/{user_id} | PATCH | user | write | +| Delete user | /users/{user_id} | DELETE | user | delete | +| Invite a new user | /users/invite_users | POST | invite_user | write | +| Get Current Authentication Info | /users/me/auth_info | GET | N/A | N/A | +| Get Permssions for a role | /authorization/permissions | GET | N/A | N/A | +| Check Authorization for a permission and role | /authorization/authorize | POST | N/A | N/A | +| Create Custom roles for RBAC | /authorization/custom_roles | POST | custom_roles | write | +| Delete Custom Roles for RBAC | /authorization/custom_roles | DELETE | custom_roles | delete | +| Get configured custom roles for RBAC | /authorization/custom_roles | GET | custom_roles | read | +| Get current organization of session | /organizations/current | GET | N/A | N/A | +| Set current organization of session | /organizations/current | PUT | N/A | N/A | +| Get usage | /usage/{rollup} | GET | organization_metrics | read | + +### Model and Data Related Permissions + +| Permission | Endpoint | REST | Resource in System | Action | +|----------------------------------------------------------|------------------------------------------------------------------------------|--------|--------------------------------------|---------| +| Get models | /models | GET | model | read | +| Create a model | /models | POST | model | write | +| Get a model's health score (most recent) | /models/health | GET | model | read | +| Get model | /models/{model_id} | GET | model | read | +| Update model | /models/{model_id} | PUT | model | write | +| Delete model | /models/{model_id} | DELETE | model | delete | +| Get model bias groups | /models/{model_id}/bias_groups | GET | model | read | +| Get attributes | /models/{model_id}/attributes | GET | model | read | +| Update attributes | /models/{model_id}/attributes | PUT | model | write | +| Edit model attributes | /models/{model_id}/attributes | PATCH | model | write | +| Delete model attributes | /models/{model_id}/attributes | DELETE | model | delete | +| Get an attribute | /models/{model_id}/attributes/{attribute_id} | GET | model | read | +| Update an attribute | /models/{model_id}/attributes/{attribute_id} | PUT | model | write | +| Delete an attribute | /models/{model_id}/attributes/{attribute_id} | DELETE | model | delete | +| Get tags | /tags | GET | tag | read | +| Update a tag | /tags/{tag_name} | PUT | tag | write | +| Delete a tag | /tags/{tag_name} | DELETE | tag | delete | +| Get model groups | /model_groups | GET | model_group | read | +| Get a model group | /model_groups/{model_group_id} | GET | model_group | read | +| Update a model group | /model_groups/{model_group_id} | PATCH | model_group | write | +| Delete a model group | /model_groups/{model_group_id} | DELETE | model_group | delete | +| Get a model group's versions | /model_groups/{model_group_id}/versions | GET | model_group | read | +| Get latest version for a model group | /model_groups/{model_group_id}/versions/latest | GET | model_group | read | +| Retrieve the prediction and explanation for an inference | /models/{model_id}/what_if | POST | raw_data | read | +| Generate on-demand explanation for an inference | /models/{model_id}/inferences/{partner_inference_id}/explanation | GET | raw_data | read | +| Save inferences | /models/{model_id}/inferences | POST | raw_data | write | +| Save inferences from file | /models/{model_id}/inferences/file | POST | raw_data | write | +| Update inferences | /models/{model_id}/inferences | PATCH | raw_data | write | +| Get image inference | /models/{model_id}/inferences/images/{image_id} | GET | raw_data | read | +| Get batch information for batch of a model | /models/{model_id}/batches/{batch_id} | GET | raw_data | read | +| Closes a batch | /models/{model_id}/batches/{batch_id} | PATCH | raw_data | write | +| Get inference | /models/{model_id}/inferences/query/{partner_inference_id} | GET | raw_data | read | +| Get all datasets for a model | /models/{model_id}/datasets | GET | raw_data | read | +| Get reference data information for model | /models/{model_id}/reference_data | GET | reference_data | read | +| Closes a reference dataset | /models/{model_id}/reference_data | PATCH | reference_data | write | +| Uploads a parquet file containing reference set data | /models/{model_id}/reference_data | POST | reference_data | write | +| Execute query | /models/{model_id}/inferences/query | POST | query (✱ see footnote) | execute | +| Execute query and retrun data drift values | /models/{model_id}/inferences/query/data_drift | POST | query | execute | +| Execute query and return psi buckets | /models/{model_id}/inferences/query/data_drift_psi_bucket_calculation_table | POST | query | execute | +| Execute query and return scatterplot distributions | /models/{model_id}/inferences/query/distribution | POST | query | execute | +| Get bias mitigation curves | /models/{model_id}/bias_mitigation_curves/attributes/{attribute_id} | GET | raw_data | read | +| Get bias mitigation curves | /models/{model_id}/enrichments/bias_mitigation/curves | GET | raw_data | read | +| Find Hotspots | /models/{model_id}/enrichments/hotspots/find | GET | raw_data | read | +| Get metric queries | /models/{model_id}/metrics | GET | metric_query | read | +| Create a metric query | /models/{model_id}/metrics | POST | metric_query | write | +| Get a metric query | /models/{model_id}/metrics/{metric_id} | GET | metric_query | read | +| Update a metric query | /models/{model_id}/metrics/{metric_id} | PUT | metric_query | write | +| Delete a metric query | /models/{model_id}/metrics/{metric_id} | DELETE | metric_query | delete | +| Get all enrichment configs | /models/{model_id}/enrichments | GET | enrichment_config | read | +| Update an enrichment config | /models/{model_id}/enrichments | PATCH | enrichment_config | write | +| Get explainability config | /models/{model_id}/enrichments/explainability | GET | enrichment_config | read | +| Update explainability config | /models/{model_id}/enrichments/explainability | PATCH | enrichment_config | write | +| Get anomaly detection config | /models/{model_id}/enrichments/anomaly_detection | GET | enrichment_config | read | +| Update anomaly detection config | /models/{model_id}/enrichments/anomaly_detection | PATCH | enrichment_config | write | +| Get bias mitigation config | /models/{model_id}/enrichments/bias_mitigation | GET | enrichment_config | read | +| Update bias mitigation config | /models/{model_id}/enrichments/bias_mitigation | PATCH | enrichment_config | write | +| Get hotspots config | /models/{model_id}/enrichments/hotspots | GET | enrichment_config | read | +| Update hotspots config | /models/{model_id}/enrichments/hotspots | PATCH | enrichment_config | write | + +✱ `POST` `/models/{model_id}/inferences/query` requires both `query`|`execute` permissions as well as EITHER `raw_data`|`read` OR `reference_data`|`read` permissions depending on what the posted query is. + + + +### Alert Related Permissions + +| Permission | Endpoint | REST | Resource in System | Action | +|----------------------------------------------------------|------------------------------------------------------------------------------|--------|--------------------------------------|---------| +| Create an alert rule | /models/{model_id}/alert_rules | POST | alert_rule | write | +| Get alert rules | /models/{model_id}/alert_rules | GET | alert_rule | read | +| Delete an alert rule | /models/{model_id}/alert_rules/{alert_rule_id} | DELETE | alert_rule | delete | +| Edit an alert rule | /models/{model_id}/alert_rules/{alert_rule_id} | PATCH | alert_rule | write | +| Bulk resolve alert for an alert rule | /models/{model_id}/alert_rules/{alert_rule_id}/bulk_alerts | PATCH | alert | resolve | +| Get alerts | /alerts | GET | alert | read | +| Get alert counts by model | /alerts/model_counts | GET | alert | read | +| Update alert status | /alerts/{alert_id} | PATCH | alert | resolve | +| Send manual alert notification | /alerts/{alert_id}/notifications | POST | alert | notify | +| Get alert notification configurations | /alert_notification_configurations | GET | alert_notification_config | read | +| Create an alert notification configuration | /alert_notification_configurations | POST | alert_notification_config | write | +| Get an alert notification configuration | /alert_notification_configurations/{configuration_id} | GET | alert_notification_config | read | +| Edit an alert notification configuration | /alert_notification_configurations/{configuration_id} | PATCH | alert_notification_config | write | +| Delete an alert notification configuration | /alert_notification_configurations/{configuration_id} | DELETE | alert_notification_config | delete | +| Get insights | /models/{model_id}/insights | GET | insight | read | +| Update the status of insights | /models/{model_id}/insights | PATCH | insight | resolve | +| Get an insight | /models/{model_id}/insights/{insight_id} | GET | insight | write | +| Update the status of an insight | /models/{model_id}/insights/{insight_id} | PATCH | insight | resolve | +| Get all alert summary configurations | /alert_summary_configurations | GET | alert_summary_config | read | +| Create an alert summary configuration | /alert_summary_configurations | POST | alert_summary_config | write | +| Get an alert summary configuration | /alert_summary_configurations/{configuration_id} | GET | alert_summary_config | read | +| Delete an alert summary configuration | /alert_summary_configurations/{configuration_id} | DELETE | alert_summary_config | delete | +| Update an alert summary configuration | /alert_summary_configurations/{configuration_id} | PATCH | alert_summary_config | write | +| Get all alert summary subscribers | /alert_summary_configurations/{configuration_id}/subscribers | GET | alert_summary_subscriber | read | +| Create an alert summary subscriber | /alert_summary_configurations/{configuration_id}/subscribers | POST | alert_summary_subscriber | write | +| Get an alert summary subscriber | /alert_summary_configurations/{configuration_id}/subscribers/{subscriber_id} | GET | alert_summary_subscriber | read | +| Update an alert summary subscriber | /alert_summary_configurations/{configuration_id}/subscribers/{subscriber_id} | PATCH | alert_summary_subscriber | write | +| Delete an alert summary subscriber | /alert_summary_configurations/{configuration_id}/subscribers/{subscriber_id} | DELETE | alert_summary_subscriber | delete | +| Send manual alert summary notifications to subscribers | /alert_summary_configurations/{configuration_id}/notifications | POST | alert_summary | notify | diff --git a/files/arthur-docs-markdown/platform-management/reference/permissions_by_standard_roles.md.txt b/files/arthur-docs-markdown/platform-management/reference/permissions_by_standard_roles.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7108f704529820ddc3b3de93fdd9c933682ab5ff --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/permissions_by_standard_roles.md.txt @@ -0,0 +1,59 @@ +## Arthur Permissions by Standard Roles + +| | | Model Reader | Alert Manager | User | Model Writer | Free Tier User | Model Owner | Org Manager | Administrator | Org Creator | Super Admin | +|---------------------------|---------|--------------|---------------|------|--------------|----------------|-------------|-------------|---------------|-------------|-------------| +| user | read | X | | X | | X | X | | X | | X | +| model | read | X | | X | | X | X | | X | | X | +| tag | read | X | | X | | X | X | | X | | X | +| model_group | read | X | | X | | X | X | | X | | X | +| alert_rule | read | X | | X | | X | X | | X | | X | +| alert | read | X | | X | | X | X | | X | | X | +| alert | resolve | | X | X | | X | X | | X | | X | +| alert_notification_config | read | X | | X | | X | X | | X | | X | +| alert_notification_config | write | | X | X | | X | X | | X | | X | +| alert_notification_config | delete | | X | X | | X | X | | X | | X | +| insight | read | X | | X | | X | X | | X | | X | +| insight | resolve | | X | X | | X | X | | X | | X | +| alert_summary_config | read | X | | X | | X | X | | X | | X | +| alert_summary_config | write | | X | X | | X | X | | X | | X | +| alert_summary_config | delete | | X | X | | X | X | | X | | X | +| alert_summary_subscriber | read | X | | X | | X | X | | X | | X | +| alert_summary_subscriber | write | | X | X | | X | X | | X | | X | +| alert_summary_subscriber | delete | | X | X | | X | X | | X | | X | +| reference_data | read | | | X | | X | X | | X | | X | +| raw_data | read | | | X | | X | X | | X | | X | +| query | execute | | | X | | X | X | | X | | X | +| metric_query | read | X | | X | | X | X | | X | | X | +| enrichment_config | read | X | | X | | X | X | | X | | X | +| model | write | | | | X | X | X | | X | | X | +| model | delete | | | | X | X | X | | X | | X | +| tag | write | | | | X | X | X | | X | | X | +| tag | delete | | | | X | X | X | | X | | X | +| model_group | write | | | | X | X | X | | X | | X | +| model_group | delete | | | | X | X | X | | X | | X | +| alert_rule | write | | | | X | X | X | | X | | X | +| alert_rule | delete | | | | X | X | X | | X | | X | +| metric_query | write | | | | X | X | X | | X | | X | +| metric_query | delete | | | | X | X | X | | X | | X | +| reference_data | write | | | | | X | X | | X | | X | +| raw_data | write | | | | | X | X | | X | | X | +| enrichment_config | write | | | | X | | X | | X | | X | +| organization_metrics | read | | | | | X | X | | X | | X | +| service_account | read | | | | | X | X | | X | | X | +| service_account | write | | | | | X | X | | X | | X | +| service_account | delete | | | | | X | X | | X | | X | +| invite_user | write | | | | | X | | X | X | | X | +| user | write | | | | | | | X | X | | X | +| user | delete | | | | | | | X | X | | X | +| authentication_config | read | | | | | | | X | X | | X | +| authentication_config | write | | | | | | | X | X | | X | +| alert | notify | | | | | | | | X | | X | +| alert_summary | notify | | | | | | | | X | | X | +| organization_global | read | | | | | | | | | X | X | +| organization_global | write | | | | | | | | | X | X | +| organization | read | | | | | | | | | X | X | +| organization | delete | | | | | | | | | X | X | +| custom_roles | read | | | | | | | | | X | X | +| custom_roles | write | | | | | | | | | X | X | +| custom_roles | delete | | | | | | | | | X | X | +| system_config | write | | | | | | | | | | X | \ No newline at end of file diff --git a/files/arthur-docs-markdown/platform-management/reference/permissions_set.md.txt b/files/arthur-docs-markdown/platform-management/reference/permissions_set.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..437c1ccc420f54aba5a2d6c790c8b76b4642a185 --- /dev/null +++ b/files/arthur-docs-markdown/platform-management/reference/permissions_set.md.txt @@ -0,0 +1,106 @@ +## Full Directory of Arthur Permissions +These can be used to specify permissions in the custom role mapping configuration JSON under "resource" and "action". + +``` +EX: +* "Resource" + * "Action" + * "Action" + * "Action" +``` + +### Org and User Related Permissions + +* organization_global + * read + * write + +* organization + * read + * delete + +* custom_roles + * read + * write + * delete + +* system_config + * write + +* user + * read + * write + * delete + +* user_invite + * write + +* organization_metrics + * read + +### Model Related Permissions + +* model + * read + * write + * delete + +* model_group + * read + * write + * delete + +* tag + * read + * write + * delete + +* enrichment_config + * read + * write + +* metric_query + * read + * write + * delete + +* raw_data + * read + * write + +* query + * execute + +### Alert Related Permissions + +* alert + * read + * resolve + * notify + +* insight + * read + * resolve + +* alert_rule + * read + * write + * delete + +* alert_notification_config + * read + * write + * delete + +* alert_summary + * notify + +* alert_summary_config + * read + * write + * delete + +* alert_summary_subscriber + * read + * write + * delete \ No newline at end of file diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.apiv3.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.apiv3.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ec06873a3a088ab1ec702134625244727ce818d8 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.apiv3.md.txt @@ -0,0 +1,419 @@ + + + + + + +arthurai.client.apiv3 - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](#) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.apiv3[#](#module-arthurai.client.apiv3 "Permalink to this headline") +==================================================================================== + + +SDK Version 2 backward compatibility + + +This convenience module provides compatibility with the ArthurAI SDK version 2.x, but is considered deprecated. Please +update your import paths according to the following: + + +* arthurai.client.apiv3.InputType → arthurai.common.constants.InputType +* arthurai.client.apiv3.OutputType → arthurai.common.constants.OutputType +* arthurai.client.apiv3.ValueType → arthurai.common.constants.ValueType +* arthurai.client.apiv3.Stage → arthurai.common.constants.Stage +* arthurai.client.apiv3.TextDelimiter → arthurai.common.constants.TextDelimiter +* arthurai.client.apiv3.ListableStrEnum → arthurai.common.constants.ListableStrEnum +* arthurai.client.apiv3.AttributeCategory → arthurai.core.attributes.AttributeCategory +* arthurai.client.apiv3.AttributeBin → arthurai.core.attributes.AttributeBin +* arthurai.client.apiv3.arthur\_explainer → arthurai.explainability.arthur\_explainer +* arthurai.client.apiv3.decorators → arthurai.core.decorators +* arthurai.client.apiv3.explanation\_packager → arthurai.explainability.explanation\_packager + + + + + + + +[Next + +arthurai.client.client](arthurai.client.client.html) +[Previous + +arthurai.client](arthurai.client.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.client.ArthurAI.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.client.ArthurAI.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..b7098b560a8b7ef38698bb4582fe6dac913cd7f0 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.client.ArthurAI.md.txt @@ -0,0 +1,650 @@ + + + + + + +arthurai.client.client.ArthurAI - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](#) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.client.ArthurAI[#](#arthurai-client-client-arthurai "Permalink to this headline") +================================================================================================= + + + + +*class* arthurai.client.client.ArthurAI(*config=None*, *verify\_ssl=None*, *url=None*, *access\_key=None*, *offline=False*, *login=None*, *password=None*, *organization\_id=None*)[#](#arthurai.client.client.ArthurAI "Permalink to this definition") +Bases: `object` + + +A client that interacts with Arthur’s servers. + + +Methods + + + + + + + + +| [`create\_service\_account`](#arthurai.client.client.ArthurAI.create_service_account "arthurai.client.client.ArthurAI.create_service_account") | Create a new service account | +| [`get\_current\_org`](#arthurai.client.client.ArthurAI.get_current_org "arthurai.client.client.ArthurAI.get_current_org") | Retrieves the current organization that the client is operating in | +| [`get\_model`](#arthurai.client.client.ArthurAI.get_model "arthurai.client.client.ArthurAI.get_model") | Retrieve an existing model by id | +| [`get\_model\_group`](#arthurai.client.client.ArthurAI.get_model_group "arthurai.client.client.ArthurAI.get_model_group") | (BETA) Retrieve an existing model group by id | +| [`get\_service\_accounts`](#arthurai.client.client.ArthurAI.get_service_accounts "arthurai.client.client.ArthurAI.get_service_accounts") | Retrieve service accounts | +| [`model`](#arthurai.client.client.ArthurAI.model "arthurai.client.client.ArthurAI.model") | Create a new multistage model. | +| [`set\_current\_org`](#arthurai.client.client.ArthurAI.set_current_org "arthurai.client.client.ArthurAI.set_current_org") | Sets the current organization that the client's requests apply to | + + + + + +create\_service\_account(*description*, *role*)[#](#arthurai.client.client.ArthurAI.create_service_account "Permalink to this definition") +Create a new service account + + + +Parameters +* **description** (`str`) – the description for the new service account +* **role** ([`Role`](arthurai.common.constants.Role.html#arthurai.common.constants.Role "arthurai.common.constants.Role")) – the Role of the new service account + + + +Returns +parsed response in the following format: + + + +``` +{ + "id": "", + "organization\_id": "", + "description": "", + "token": "" +} + +``` + + + + + + + +get\_current\_org()[#](#arthurai.client.client.ArthurAI.get_current_org "Permalink to this definition") +Retrieves the current organization that the client is operating in + + + +Return type +`Dict`[`str`, `str`] + + + +Returns +a string with the UUID of the current organization + + + +Permissions +N/A + + + + + + + +get\_model(*identifier*, *id\_type='id'*)[#](#arthurai.client.client.ArthurAI.get_model "Permalink to this definition") +Retrieve an existing model by id + + + +Param +identifier: Id to get the model by + + + +Param +id\_type: Type of id the identifier is, possible options are [‘id’, ‘partner\_model\_id’] + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +model read + + + +Return type +[`ArthurModel`](arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel "arthurai.core.models.ArthurModel") + + + + + + + +get\_model\_group(*id\_or\_model*)[#](#arthurai.client.client.ArthurAI.get_model_group "Permalink to this definition") +(BETA) Retrieve an existing model group by id + + + +Param +identifier: Id to get the model group by + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +model\_group read + + + +Return type +[`ArthurModelGroup`](arthurai.core.models.ArthurModelGroup.html#arthurai.core.models.ArthurModelGroup "arthurai.core.models.ArthurModelGroup") + + + + + + + +get\_service\_accounts(*description=None*)[#](#arthurai.client.client.ArthurAI.get_service_accounts "Permalink to this definition") +Retrieve service accounts + + + +Parameters +**description** (`Optional`[`str`]) – an optional description that returned account should match + + + +Returns +parsed response containing a list of service accounts, in the following format: + + + +``` +[ + { + "id": "", + "organization\_id": "", + "description": "", + "token": "" + } +] + +``` + + + + + + + +model(*partner\_model\_id*, *input\_type*, *output\_type=None*, *model\_type=None*, *display\_name=None*, *description=None*, *tags=None*, *classifier\_threshold=None*, *is\_batch=False*, *text\_delimiter=None*, *expected\_throughput\_gb\_per\_day=None*, *pixel\_height=None*, *pixel\_width=None*)[#](#arthurai.client.client.ArthurAI.model "Permalink to this definition") +Create a new multistage model. + + + +Parameters +* **partner\_model\_id** (`str`) – The string external id of the model +* **input\_type** ([`InputType`](arthurai.common.constants.InputType.html#arthurai.common.constants.InputType "arthurai.common.constants.InputType")) – the [`InputType`](arthurai.common.constants.InputType.html#arthurai.common.constants.InputType "arthurai.common.constants.InputType") +* **output\_type** (`Optional`[[`OutputType`](arthurai.common.constants.OutputType.html#arthurai.common.constants.OutputType "arthurai.common.constants.OutputType")]) – the [`OutputType`](arthurai.common.constants.OutputType.html#arthurai.common.constants.OutputType "arthurai.common.constants.OutputType") +* **model\_type** (`Optional`[[`OutputType`](arthurai.common.constants.OutputType.html#arthurai.common.constants.OutputType "arthurai.common.constants.OutputType")]) – + + +Deprecated since version version: 2.0.0 Use output\_type instead. +* **display\_name** (`Optional`[`str`]) – Optional name to display on dashboard, will default to the external id +* **description** (`Optional`[`str`]) – Optional description for the model +* **tags** (`Optional`[`List`[`str`]]) – A list of string tags to associate with the model +* **classifier\_threshold** (`Optional`[`float`]) – For binary classification models this is the threshold to determine a positive class, defaults to 0.5 +* **is\_batch** (`bool`) – boolean value which signifies whether the model sends inferences by batch or streaming +* **text\_delimiter** (`Optional`[[`TextDelimiter`](arthurai.common.constants.TextDelimiter.html#arthurai.common.constants.TextDelimiter "arthurai.common.constants.TextDelimiter")]) – TextDelimiter used in NLP models to split documents into tokens for explanations +* **expected\_throughput\_gb\_per\_day** (`Optional`[`int`]) – Expected amount of throughput. Used to provision resources +* **pixel\_height** (`Optional`[`int`]) – Image height in pixels. Needed for CV models which require images to be one size +* **pixel\_width** (`Optional`[`int`]) – Image width in pixels. Needed for CV models which require images to be one size + + + +Return type +[`ArthurModel`](arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel "arthurai.core.models.ArthurModel") + + + +Returns +An `ArthurModel` + + + + + + + +set\_current\_org(*org\_id*)[#](#arthurai.client.client.ArthurAI.set_current_org "Permalink to this definition") +Sets the current organization that the client’s requests apply to + + + +Parameters +**org\_id** (`str`) – The ID of the organization to set + + + +Return type +`None` + + + +Returns +None + + + +Permissions +N/A + + + + + + + + + + + +[Next + +arthurai.client.helper](arthurai.client.helper.html) +[Previous + +arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.client.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.client.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..fe688c648847a9050c65f79c55cb008ff5e5ad7a --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.client.md.txt @@ -0,0 +1,443 @@ + + + + + + +arthurai.client.client - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](#)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.client[#](#module-arthurai.client.client "Permalink to this headline") +====================================================================================== + + +Functions + + + + + + + + +| [`new\_requests\_client`](arthurai.client.client.new_requests_client.html#arthurai.client.client.new_requests_client "arthurai.client.client.new_requests_client")([access\_key, url, ...]) | +rtype +[`HTTPClient`](arthurai.client.http.requests.HTTPClient.html#arthurai.client.http.requests.HTTPClient "arthurai.client.http.requests.HTTPClient") + + | + + + +Classes + + + + + + + + +| [`ArthurAI`](arthurai.client.client.ArthurAI.html#arthurai.client.client.ArthurAI "arthurai.client.client.ArthurAI")([config, verify\_ssl, url, ...]) | A client that interacts with Arthur's servers. | + + + + + + + + +[Next + +arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) +[Previous + +arthurai.client.apiv3](arthurai.client.apiv3.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + On this page + + + + +* [arthurai.client.client](#) + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.client.new_requests_client.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.client.new_requests_client.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6db62360fe7644f3e2e4157790a484e336e24d97 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.client.new_requests_client.md.txt @@ -0,0 +1,410 @@ + + + + + + +arthurai.client.client.new\_requests\_client - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](#) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.client.new\_requests\_client[#](#arthurai-client-client-new-requests-client "Permalink to this headline") +========================================================================================================================= + + + + +arthurai.client.client.new\_requests\_client(*access\_key=None*, *url=None*, *verify\_ssl=True*, *offline=False*, *organization\_id=None*)[#](#arthurai.client.client.new_requests_client "Permalink to this definition") + +Return type +[`HTTPClient`](arthurai.client.http.requests.HTTPClient.html#arthurai.client.http.requests.HTTPClient "arthurai.client.http.requests.HTTPClient") + + + + + + + + + + +[Next + +arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) +[Previous + +arthurai.client.client](arthurai.client.client.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.helper.construct_url.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.helper.construct_url.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..fd1b8c25cfc3f695408a0db57f131daea279e199 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.helper.construct_url.md.txt @@ -0,0 +1,430 @@ + + + + + + +arthurai.client.helper.construct\_url - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](#) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.helper.construct\_url[#](#arthurai-client-helper-construct-url "Permalink to this headline") +============================================================================================================ + + + + +arthurai.client.helper.construct\_url(*\*parts*, *validate=True*, *default\_https=True*)[#](#arthurai.client.helper.construct_url "Permalink to this definition") +Construct a url from various parts + + +Useful for joining pieces which may or may not have leading and/or trailing +slashes. e.g. construct\_url(””, “/api/v3”, “/users”) will yield the same valid url as +construct\_url(””, “api/v3/”, “users/”). + + + +Parameters +* **validate** – if True, validate that the URL is valid +* **default\_https** – if True, allow urls without a scheme and use https by default +* **parts** (`str`) – strings from which to construct the url + + + +Return type +`str` + + + +Returns +a fully joined url + + + + + + + + + + +[Next + +arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) +[Previous + +arthurai.client.helper](arthurai.client.helper.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_auth_info.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_auth_info.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..bc7f9040d96198e461284830143e0d825a8bb837 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_auth_info.md.txt @@ -0,0 +1,431 @@ + + + + + + +arthurai.client.helper.get\_auth\_info - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](#) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.helper.get\_auth\_info[#](#arthurai-client-helper-get-auth-info "Permalink to this headline") +============================================================================================================= + + + + +arthurai.client.helper.get\_auth\_info(*api\_http\_host*, *api\_prefix*, *access\_key*, *verify\_ssl=True*)[#](#arthurai.client.helper.get_auth_info "Permalink to this definition") +Get the AuthInfo struct associated with the provided access key + + + +Parameters +* **api\_http\_host** (`str`) – base url of the host to connect to, including protocol (e.g. “”) +* **api\_prefix** (`str`) – prefix of the API to connect to (e.g. “/api/v3”) +* **access\_key** (`str`) – API token to pass to the API +* **verify\_ssl** (`bool`) – Boolean for whether requests should verify that the SSL certificate is valid and not self-signed + + + +Return type +`Optional`[[`AuthInfo`](arthurai.core.auth_info.AuthInfo.html#arthurai.core.auth_info.AuthInfo "arthurai.core.auth_info.AuthInfo")] + + + +Returns +the AuthInfo associated with the provided access key + + + +Permissions +N/A + + + + + + + + + + +[Next + +arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) +[Previous + +arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_current_org.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_current_org.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d48b4b985d79efedb1b5eb27cc124f22e7a473d9 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.helper.get_current_org.md.txt @@ -0,0 +1,426 @@ + + + + + + +arthurai.client.helper.get\_current\_org - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](#) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.helper.get\_current\_org[#](#arthurai-client-helper-get-current-org "Permalink to this headline") +================================================================================================================= + + + + +arthurai.client.helper.get\_current\_org(*api\_http\_host*, *api\_prefix*, *access\_key*, *verify\_ssl=True*)[#](#arthurai.client.helper.get_current_org "Permalink to this definition") +Get the current organization for the provided access key + + + +Parameters +* **api\_http\_host** (`str`) – base url of the host to connect to, including protocol (e.g. “”) +* **api\_prefix** (`str`) – prefix of the API to connect to (e.g. “/api/v3”) +* **access\_key** (`str`) – API Key to pass to the API +* **verify\_ssl** (`bool`) – Boolean for whether requests should verify that the SSL certificate is valid and not self-signed + + + +Return type +`Optional`[`str`] + + + +Returns +the organization ID associated with the provided access key, None if no such organization exists + + + + + + + + + + +[Next + +arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) +[Previous + +arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.helper.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.helper.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..51a68772a8602e21d2135bbf896e0e77586fbf7c --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.helper.md.txt @@ -0,0 +1,416 @@ + + + + + + +arthurai.client.helper - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](#)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.helper[#](#module-arthurai.client.helper "Permalink to this headline") +====================================================================================== + + +Functions + + + + + + + + +| [`construct\_url`](arthurai.client.helper.construct_url.html#arthurai.client.helper.construct_url "arthurai.client.helper.construct_url")(\*parts[, validate, default\_https]) | Construct a url from various parts | +| [`get\_arthur\_internal\_user\_org`](arthurai.client.helper.get_arthur_internal_user_org.html#arthurai.client.helper.get_arthur_internal_user_org "arthurai.client.helper.get_arthur_internal_user_org")(api\_http\_host, ...) | Get the current organization for the provided Arthur access key belonging to an Arthur internal user | +| [`get\_auth\_info`](arthurai.client.helper.get_auth_info.html#arthurai.client.helper.get_auth_info "arthurai.client.helper.get_auth_info")(api\_http\_host, api\_prefix, ...) | Get the AuthInfo struct associated with the provided access key | +| [`get\_current\_org`](arthurai.client.helper.get_current_org.html#arthurai.client.helper.get_current_org "arthurai.client.helper.get_current_org")(api\_http\_host, api\_prefix, ...) | Get the current organization for the provided access key | +| [`user\_login`](arthurai.client.helper.user_login.html#arthurai.client.helper.user_login "arthurai.client.helper.user_login")(api\_http\_host, api\_prefix, login, ...) | Get the current organization for the provided access key | + + + + + + + + +[Next + +arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) +[Previous + +arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.helper.user_login.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.helper.user_login.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7f7e4b8f1fd78895519c420166137701cca50c25 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.helper.user_login.md.txt @@ -0,0 +1,427 @@ + + + + + + +arthurai.client.helper.user\_login - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](#) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.helper.user\_login[#](#arthurai-client-helper-user-login "Permalink to this headline") +====================================================================================================== + + + + +arthurai.client.helper.user\_login(*api\_http\_host*, *api\_prefix*, *login*, *password*, *verify\_ssl=True*)[#](#arthurai.client.helper.user_login "Permalink to this definition") +Get the current organization for the provided access key + + + +Parameters +* **api\_http\_host** (`str`) – base url of the host to connect to, including protocol (e.g. “”) +* **api\_prefix** (`str`) – prefix of the API to connect to (e.g. “/api/v3”) +* **login** (`str`) – the username or password to use to log in +* **password** (`str`) – password for the user +* **verify\_ssl** (`bool`) – Boolean for whether requests should verify that the SSL certificate is valid and not self-signed + + + +Return type +`Tuple`[`str`, `Dict`[`str`, `Any`]] + + + +Returns +a tuple of (access\_key, {user object}) + + + + + + + + + + +[Next + +arthurai.client.http](arthurai.client.http.html) +[Previous + +arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.http.arthur.ArthurHTTPClient.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.http.arthur.ArthurHTTPClient.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2d02360d8aac7a5c1269ac473a2f83a729607f2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.http.arthur.ArthurHTTPClient.md.txt @@ -0,0 +1,568 @@ + + + + + + +arthurai.client.http.arthur.ArthurHTTPClient - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](#) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.http.arthur.ArthurHTTPClient[#](#arthurai-client-http-arthur-arthurhttpclient "Permalink to this headline") +=========================================================================================================================== + + + + +*class* arthurai.client.http.arthur.ArthurHTTPClient(*access\_key=None*, *url=None*, *base\_path=None*, *thread\_workers=10*, *verify\_ssl=True*, *offline=False*)[#](#arthurai.client.http.arthur.ArthurHTTPClient "Permalink to this definition") +Bases: [`arthurai.client.http.base.AbstractHTTPClient`](arthurai.client.http.base.AbstractHTTPClient.html#arthurai.client.http.base.AbstractHTTPClient "arthurai.client.http.base.AbstractHTTPClient") + + +An HTTPClient that uses Arthur-specific parameters + + + +Deprecated since version 3.13.1. + + + +Methods + + + + + + + + +| [`async\_call`](#arthurai.client.http.arthur.ArthurHTTPClient.async_call "arthurai.client.http.arthur.ArthurHTTPClient.async_call") | Starts a new process asynchronously | +| [`delete`](#arthurai.client.http.arthur.ArthurHTTPClient.delete "arthurai.client.http.arthur.ArthurHTTPClient.delete") | Sends a DELETE request to the given url with the given headers | +| [`get`](#arthurai.client.http.arthur.ArthurHTTPClient.get "arthurai.client.http.arthur.ArthurHTTPClient.get") | Sends a GET request to the given url with the given headers :param retries: Number of times to retry the request if it results in a 400 or higher response code :param return\_raw\_response: If true do not filter response, return raw object :param url: url to send request to :param headers: headers to use in the request :return: response of the rest call | +| [`patch`](#arthurai.client.http.arthur.ArthurHTTPClient.patch "arthurai.client.http.arthur.ArthurHTTPClient.patch") | Sends a PATCH request to the given url with the given headers | +| [`post`](#arthurai.client.http.arthur.ArthurHTTPClient.post "arthurai.client.http.arthur.ArthurHTTPClient.post") | Sends a POST request to the given url with the given headers | +| [`put`](#arthurai.client.http.arthur.ArthurHTTPClient.put "arthurai.client.http.arthur.ArthurHTTPClient.put") | Sends a PUT request to the given url with the given headers :param return\_raw\_response: If true do not filter response, return raw object :param url: url to send request to :param headers: headers to use in the request :param retries: Number of times to retry the request if it results in a 400 or higher response code :return: response of the rest call | +| [`send`](#arthurai.client.http.arthur.ArthurHTTPClient.send "arthurai.client.http.arthur.ArthurHTTPClient.send") | Sends the specified data with headers to the given url with the given request type | + + + + + +*static* async\_call(*rest\_call*, *pool*, *\*args*, *callback=None*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.async_call "Permalink to this definition") +Starts a new process asynchronously + + + +Parameters +* **rest\_call** – a pointer to the rest call which should be executed async +* **pool** – python process pool to take processes from +* **callback** – function which will get called given the response of the child thread + + + +Returns +returns a python AsyncResult object + + + + + + + +delete(*url*, *headers=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.delete "Permalink to this definition") +Sends a DELETE request to the given url with the given headers + + + +Parameters +* **return\_raw\_response** – If true do not filter response, return raw object +* **url** – url to send request to +* **headers** – headers to use in the request +* **retries** – Number of times to retry the request if it results in a 400 or higher response code + + + +Returns +response of the rest call + + + + + + + +get(*url*, *headers=None*, *params=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.get "Permalink to this definition") +Sends a GET request to the given url with the given headers +:param retries: Number of times to retry the request if it results in a 400 or higher response code +:param return\_raw\_response: If true do not filter response, return raw object +:param url: url to send request to +:param headers: headers to use in the request +:return: response of the rest call + + + + + +patch(*url*, *json=None*, *files=None*, *headers=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.patch "Permalink to this definition") +Sends a PATCH request to the given url with the given headers + + + +Parameters +* **return\_raw\_response** – If true do not filter response, return raw object +* **url** – url to send request to +* **headers** – headers to use in the request +* **retries** – Number of times to retry the request if it results in a 400 or higher response code + + + +Returns +response of the rest call + + + + + + + +post(*url*, *json=None*, *files=None*, *headers=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.post "Permalink to this definition") +Sends a POST request to the given url with the given headers + + + +Parameters +* **return\_raw\_response** – If true do not filter response, return raw object +* **url** – url to send request to +* **headers** – headers to use in the request +* **retries** – Number of times to retry the request if it results in a 400 or higher response code + + + +Returns +response of the rest call + + + + + + + +put(*url*, *json=None*, *files=None*, *headers=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.put "Permalink to this definition") +Sends a PUT request to the given url with the given headers +:param return\_raw\_response: If true do not filter response, return raw object +:param url: url to send request to +:param headers: headers to use in the request +:param retries: Number of times to retry the request if it results in a 400 or higher response code +:return: response of the rest call + + + + + +send(*url*, *method='GET'*, *json=None*, *files=None*, *params=None*, *headers=None*, *return\_raw\_response=False*, *retries=0*)[#](#arthurai.client.http.arthur.ArthurHTTPClient.send "Permalink to this definition") +Sends the specified data with headers to the given url with the given request type + + + +Parameters +* **retries** – Number of times to retry the request if it results in a 400 or higher response code +* **return\_raw\_response** – If true do not filter request response, return raw object +* **url** – url to send data to +* **method** – REST call type, POST, GET, PUT, DELETE +* **json** – the data to send +* **headers** – headers to use in the REST call + + + +Returns +response of the REST call + + + + + + + + + + + +[Next + +arthurai.client.http.base](arthurai.client.http.base.html) +[Previous + +arthurai.client.http.arthur](arthurai.client.http.arthur.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.http.base.AbstractHTTPClient.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.http.base.AbstractHTTPClient.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a3dddce95ee701ef9e75ffc4ad0124c6496c5fe5 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.http.base.AbstractHTTPClient.md.txt @@ -0,0 +1,424 @@ + + + + + + +arthurai.client.http.base.AbstractHTTPClient - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](#) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.http.base.AbstractHTTPClient[#](#arthurai-client-http-base-abstracthttpclient "Permalink to this headline") +=========================================================================================================================== + + + + +*class* arthurai.client.http.base.AbstractHTTPClient[#](#arthurai.client.http.base.AbstractHTTPClient "Permalink to this definition") +Bases: `object` + + +Methods + + + + + + + + +| `delete` | | +| `get` | | +| `patch` | | +| `post` | | +| `put` | | +| `send` | | + + + + + + + + + +[Next + +arthurai.client.http.requests](arthurai.client.http.requests.html) +[Previous + +arthurai.client.http.base](arthurai.client.http.base.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.http.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.http.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..278728169b2eb9c9751b2cd6156378efdc7420ba --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.http.md.txt @@ -0,0 +1,411 @@ + + + + + + +arthurai.client.http - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](#)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.http[#](#module-arthurai.client.http "Permalink to this headline") +================================================================================== + + + + + + + + +| [`arthurai.client.http.arthur`](arthurai.client.http.arthur.html#module-arthurai.client.http.arthur "arthurai.client.http.arthur") | | +| [`arthurai.client.http.base`](arthurai.client.http.base.html#module-arthurai.client.http.base "arthurai.client.http.base") | | +| [`arthurai.client.http.requests`](arthurai.client.http.requests.html#module-arthurai.client.http.requests "arthurai.client.http.requests") | | + + + + + + + + +[Next + +arthurai.client.http.arthur](arthurai.client.http.arthur.html) +[Previous + +arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.http.requests.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.http.requests.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..236cb6b06583dd7996c41392192c1a6a523a0201 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.http.requests.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.client.http.requests - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](#)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.http.requests[#](#module-arthurai.client.http.requests "Permalink to this headline") +==================================================================================================== + + +Classes + + + + + + + + +| [`HTTPClient`](arthurai.client.http.requests.HTTPClient.html#arthurai.client.http.requests.HTTPClient "arthurai.client.http.requests.HTTPClient")(base\_url[, path\_prefix, ...]) | A requests-based HTTP Client intended for interacting with JSON-based APIs. | + + + + + + + + +[Next + +arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) +[Previous + +arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e03faa37884aa1f4d3c6e3ffc325ce33490ab5f2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.md.txt @@ -0,0 +1,416 @@ + + + + + + +arthurai.client - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](#)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client[#](#module-arthurai.client "Permalink to this headline") +======================================================================== + + +Arthur HTTP client and general (non-model) functions + + + + + + + + +| [`arthurai.client.apiv3`](arthurai.client.apiv3.html#module-arthurai.client.apiv3 "arthurai.client.apiv3") | SDK Version 2 backward compatibility | +| [`arthurai.client.client`](arthurai.client.client.html#module-arthurai.client.client "arthurai.client.client") | | +| [`arthurai.client.helper`](arthurai.client.helper.html#module-arthurai.client.helper "arthurai.client.helper") | | +| [`arthurai.client.http`](arthurai.client.http.html#module-arthurai.client.http "arthurai.client.http") | | +| [`arthurai.client.validation`](arthurai.client.validation.html#module-arthurai.client.validation "arthurai.client.validation") | | + + + + + + + + +[Next + +arthurai.client.apiv3](arthurai.client.apiv3.html) +[Previous + +arthurai](arthurai.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.validation.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.validation.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3168a4a67d02a1f7f091030602f9212949873353 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.validation.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.client.validation - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](#)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.validation[#](#module-arthurai.client.validation "Permalink to this headline") +============================================================================================== + + +Functions + + + + + + + + +| [`validate\_multistatus\_response\_and\_get\_failures`](arthurai.client.validation.validate_multistatus_response_and_get_failures.html#arthurai.client.validation.validate_multistatus_response_and_get_failures "arthurai.client.validation.validate_multistatus_response_and_get_failures")(...) | Validate a 207 MultiStatus response and return the failures it contains. | +| [`validate\_response\_status`](arthurai.client.validation.validate_response_status.html#arthurai.client.validation.validate_response_status "arthurai.client.validation.validate_response_status")(response\_or\_code[, ...]) | Validate the status code of a requests.Response object or (int) status code. | + + + + + + + + +[Next + +arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) +[Previous + +arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_multistatus_response_and_get_failures.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_multistatus_response_and_get_failures.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..29951e80fd4cc57ec0d51b3846d16593a912800b --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_multistatus_response_and_get_failures.md.txt @@ -0,0 +1,453 @@ + + + + + + +arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](#) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures[#](#arthurai-client-validation-validate-multistatus-response-and-get-failures "Permalink to this headline") +========================================================================================================================================================================================== + + + + +arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures(*response*, *raise\_on\_failures=False*)[#](#arthurai.client.validation.validate_multistatus_response_and_get_failures "Permalink to this definition") +Validate a 207 MultiStatus response and return the failures it contains. + + + +Parameters +* **response** (`Response`) – + +requests.Response object to validate, with the following body format: + + + +``` +{ + "counts": { + "success": 0, + "failure": 0, + "total": 0 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` +* **raise\_on\_failures** (`bool`) – if True, raise an exception if the response contains any failures + + + +Return type +`Tuple`[`List`[`dict`], `List`[`dict`]] + + + +Returns +a tuple of two lists: user-caused failures and internal failures + + + +Raises +* **ArthurInternalValueError** – If the response does not have 207 status code, or is incorrectly formatted, +or ‘counts’ and ‘results’ do not agree +* **ResponseClientError** – if raise\_on\_failures and the response contains only client errors +* **ResponseServerError** – if raise\_on\_failures and the response contains server errors + + + + + + + + + + +[Next + +arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) +[Previous + +arthurai.client.validation](arthurai.client.validation.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_response_status.md.txt b/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_response_status.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..068330ff9a609fbf7adc3fc9852d35d6a8c34669 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.client.validation.validate_response_status.md.txt @@ -0,0 +1,419 @@ + + + + + + +arthurai.client.validation.validate\_response\_status - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](#) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.client.validation.validate\_response\_status[#](#arthurai-client-validation-validate-response-status "Permalink to this headline") +=========================================================================================================================================== + + + + +arthurai.client.validation.validate\_response\_status(*response\_or\_code*, *expected\_status\_code=None*, *allow\_redirects=False*)[#](#arthurai.client.validation.validate_response_status "Permalink to this definition") +Validate the status code of a requests.Response object or (int) status code. +:type response\_or\_code: `Union`[`Response`, `int`] +:param response\_or\_code: the requests.Response object or status code to validate +:type expected\_status\_code: `Optional`[`int`] +:param expected\_status\_code: the expected status code to check for. If None, all codes <300 will be valid, and 3XX +codes will be subject to allow\_redirects +:type allow\_redirects: `Optional`[`bool`] +:param allow\_redirects: if True will not raise an exception for 3XX status codes +:rtype: `None` +:return: None +:raises InternalValueError: if expected\_status\_code is not None and does not match the response code +:raises ResponseServerError: if the response has a 5XX status code +:raises ResponseClientError: if the response has a 4XX status code +:raises ResponseRedirectError: if the response has a 3XX status code + + + + + + + + +[Next + +arthurai.common](arthurai.common.html) +[Previous + +arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.AccuracyMetric.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.AccuracyMetric.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ad9078640b2e02601dfcd7c578d3fd4aa968eb0d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.AccuracyMetric.md.txt @@ -0,0 +1,442 @@ + + + + + + +arthurai.common.constants.AccuracyMetric - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](#) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.AccuracyMetric[#](#arthurai-common-constants-accuracymetric "Permalink to this headline") +=================================================================================================================== + + + + +*class* arthurai.common.constants.AccuracyMetric[#](#arthurai.common.constants.AccuracyMetric "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.AccuracyMetric.list "arthurai.common.constants.AccuracyMetric.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Accuracy` | | +| `F1` | | +| `Precision` | | +| `Recall` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.AccuracyMetric.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) +[Previous + +arthurai.common.constants](arthurai.common.constants.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.Enrichment.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Enrichment.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..520f2b87800f0d1662823a08620398b0b976535d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Enrichment.md.txt @@ -0,0 +1,445 @@ + + + + + + +arthurai.common.constants.Enrichment - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](#) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.Enrichment[#](#arthurai-common-constants-enrichment "Permalink to this headline") +=========================================================================================================== + + + + +*class* arthurai.common.constants.Enrichment[#](#arthurai.common.constants.Enrichment "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +This class contains constants for the names of enrichments + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.Enrichment.list "arthurai.common.constants.Enrichment.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `AnomalyDetection` | | +| `BiasMitigation` | | +| `Explainability` | | +| `Hotspots` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.Enrichment.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) +[Previous + +arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageContentType.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageContentType.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..c01d9fa12481cd24acbb0be8ebcb95950acbebd4 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageContentType.md.txt @@ -0,0 +1,445 @@ + + + + + + +arthurai.common.constants.ImageContentType - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](#) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.ImageContentType[#](#arthurai-common-constants-imagecontenttype "Permalink to this headline") +======================================================================================================================= + + + + +*class* arthurai.common.constants.ImageContentType[#](#arthurai.common.constants.ImageContentType "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Valid image content types supported by Arthur API + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.ImageContentType.list "arthurai.common.constants.ImageContentType.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Gif` | | +| `Jpeg` | | +| `Png` | | +| `Tiff` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.ImageContentType.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) +[Previous + +arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageResponseType.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageResponseType.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..88b4a0de0a3935fddf4a99f14d6a4239d0764bb9 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ImageResponseType.md.txt @@ -0,0 +1,445 @@ + + + + + + +arthurai.common.constants.ImageResponseType - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](#) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.ImageResponseType[#](#arthurai-common-constants-imageresponsetype "Permalink to this headline") +========================================================================================================================= + + + + +*class* arthurai.common.constants.ImageResponseType[#](#arthurai.common.constants.ImageResponseType "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Valid image response types supported by Arthur API + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.ImageResponseType.list "arthurai.common.constants.ImageResponseType.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `LimeExplanation` | | +| `RawImage` | | +| `ResizedImage` | | +| `Thumbnail` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.ImageResponseType.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) +[Previous + +arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.InputType.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.InputType.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..c6382dff2dea07862ab2039b57df8bc7263cd42c --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.InputType.md.txt @@ -0,0 +1,441 @@ + + + + + + +arthurai.common.constants.InputType - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](#) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.InputType[#](#arthurai-common-constants-inputtype "Permalink to this headline") +========================================================================================================= + + + + +*class* arthurai.common.constants.InputType[#](#arthurai.common.constants.InputType "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.InputType.list "arthurai.common.constants.InputType.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Image` | | +| `NLP` | | +| `Tabular` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.InputType.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) +[Previous + +arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.OutputType.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.OutputType.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..27999493a9c4fbda636e419758939b680dd368c2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.OutputType.md.txt @@ -0,0 +1,442 @@ + + + + + + +arthurai.common.constants.OutputType - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](#) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.OutputType[#](#arthurai-common-constants-outputtype "Permalink to this headline") +=========================================================================================================== + + + + +*class* arthurai.common.constants.OutputType[#](#arthurai.common.constants.OutputType "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.OutputType.list "arthurai.common.constants.OutputType.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Multiclass` | | +| `Multilabel` | | +| `ObjectDetection` | | +| `Regression` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.OutputType.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.Role](arthurai.common.constants.Role.html) +[Previous + +arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.Role.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Role.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..275512fa3250b2091d42c2cf05e6f9e7be0dfed2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Role.md.txt @@ -0,0 +1,441 @@ + + + + + + +arthurai.common.constants.Role - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](#) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.Role[#](#arthurai-common-constants-role "Permalink to this headline") +=============================================================================================== + + + + +*class* arthurai.common.constants.Role[#](#arthurai.common.constants.Role "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.Role.list "arthurai.common.constants.Role.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Administrator` | | +| `ModelOwner` | | +| `User` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.Role.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) +[Previous + +arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.Stage.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Stage.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2dd88cba74e455908e8eeda19323311b6ed230df --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.Stage.md.txt @@ -0,0 +1,444 @@ + + + + + + +arthurai.common.constants.Stage - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](#) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.Stage[#](#arthurai-common-constants-stage "Permalink to this headline") +================================================================================================= + + + + +*class* arthurai.common.constants.Stage[#](#arthurai.common.constants.Stage "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.Stage.list "arthurai.common.constants.Stage.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `GroundTruth` | | +| `GroundTruthClass` | | +| `ModelPipelineInput` | | +| `NonInputData` | | +| `PredictFunctionInput` | | +| `PredictedValue` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.Stage.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) +[Previous + +arthurai.common.constants.Role](arthurai.common.constants.Role.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.TextDelimiter.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.TextDelimiter.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e29d256a0003a0d725ab363fa80f7d2c28053aab --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.TextDelimiter.md.txt @@ -0,0 +1,507 @@ + + + + + + +arthurai.common.constants.TextDelimiter - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](#) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.TextDelimiter[#](#arthurai-common-constants-textdelimiter "Permalink to this headline") +================================================================================================================= + + + + +*class* arthurai.common.constants.TextDelimiter[#](#arthurai.common.constants.TextDelimiter "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +This class contains patterns that can be used as text\_delimiter for NLP models. + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.TextDelimiter.list "arthurai.common.constants.TextDelimiter.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| [`COMMA`](#arthurai.common.constants.TextDelimiter.COMMA "arthurai.common.constants.TextDelimiter.COMMA") | `","` Splits on a single comma. | +| [`COMMA\_PLUS`](#arthurai.common.constants.TextDelimiter.COMMA_PLUS "arthurai.common.constants.TextDelimiter.COMMA_PLUS") | `",+"` Splits on one or more commas. | +| [`NOT\_WORD`](#arthurai.common.constants.TextDelimiter.NOT_WORD "arthurai.common.constants.TextDelimiter.NOT_WORD") | `"\W+"` Splits on any character that is not a word. | +| [`PIPE`](#arthurai.common.constants.TextDelimiter.PIPE "arthurai.common.constants.TextDelimiter.PIPE") | `"\|"` Splits on a single pipe. | +| [`PIPE\_PLUS`](#arthurai.common.constants.TextDelimiter.PIPE_PLUS "arthurai.common.constants.TextDelimiter.PIPE_PLUS") | `"\|+"` Splits on one or more pipes. | +| [`WHITESPACE`](#arthurai.common.constants.TextDelimiter.WHITESPACE "arthurai.common.constants.TextDelimiter.WHITESPACE") | `"\s+"` Splits on whitespace. | + + + + + +COMMA *= ','*[#](#arthurai.common.constants.TextDelimiter.COMMA "Permalink to this definition") +`","` Splits on a single comma. + + +Ex: `"this ,is,,a,test" = ["this ", "is", "", "a", "test"]` + + + + + +COMMA\_PLUS *= ',+'*[#](#arthurai.common.constants.TextDelimiter.COMMA_PLUS "Permalink to this definition") +`",+"` Splits on one or more commas. + + +Ex: `"this ,is,,a,test" = ["this ", "is", "a", "test"]` + + + + + +NOT\_WORD *= '\\W+'*[#](#arthurai.common.constants.TextDelimiter.NOT_WORD "Permalink to this definition") +`"\W+"` Splits on any character that is not a word. + + +Ex: `"this  is,aaaa,,,,,test!" = ["this", "is", "aaaa", "test", ""]` + + + + + +PIPE *= '\\|'*[#](#arthurai.common.constants.TextDelimiter.PIPE "Permalink to this definition") +`"\|"` Splits on a single pipe. + + +Ex: `"this |is||a|test" = ["this ", "is", "", "a", "test"]` + + + + + +PIPE\_PLUS *= '\\|+'*[#](#arthurai.common.constants.TextDelimiter.PIPE_PLUS "Permalink to this definition") +`"\|+"` Splits on one or more pipes. + + +Ex: `"this |is||a|test" = ["this ", "is", "a", "test"]` + + + + + +WHITESPACE *= '\\s+'*[#](#arthurai.common.constants.TextDelimiter.WHITESPACE "Permalink to this definition") +`"\s+"` Splits on whitespace. + + +Ex: `"this  is,a test! " = ["this", "is,a", "test!", ""]` + + + + + +*classmethod* list()[#](#arthurai.common.constants.TextDelimiter.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) +[Previous + +arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.ValueType.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ValueType.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..fc5c46c717d1c0a63f8f4d3583af79662bff6598 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.ValueType.md.txt @@ -0,0 +1,446 @@ + + + + + + +arthurai.common.constants.ValueType - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](#) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants.ValueType[#](#arthurai-common-constants-valuetype "Permalink to this headline") +========================================================================================================= + + + + +*class* arthurai.common.constants.ValueType[#](#arthurai.common.constants.ValueType "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.common.constants.ValueType.list "arthurai.common.constants.ValueType.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Boolean` | | +| `BoundingBox` | | +| `Float` | | +| `Image` | | +| `Integer` | | +| `String` | | +| `Timestamp` | | +| `Unstructured\_Text` | | + + + + + +*classmethod* list()[#](#arthurai.common.constants.ValueType.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.common.exceptions](arthurai.common.exceptions.html) +[Previous + +arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.constants.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.constants.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..8549af4bff98b414de8aaef5c59db9ba76aa2096 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.constants.md.txt @@ -0,0 +1,422 @@ + + + + + + +arthurai.common.constants - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](#)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.constants[#](#module-arthurai.common.constants "Permalink to this headline") +============================================================================================ + + +Classes + + + + + + + + +| [`AccuracyMetric`](arthurai.common.constants.AccuracyMetric.html#arthurai.common.constants.AccuracyMetric "arthurai.common.constants.AccuracyMetric")() | | +| [`Enrichment`](arthurai.common.constants.Enrichment.html#arthurai.common.constants.Enrichment "arthurai.common.constants.Enrichment")() | This class contains constants for the names of enrichments | +| [`ImageContentType`](arthurai.common.constants.ImageContentType.html#arthurai.common.constants.ImageContentType "arthurai.common.constants.ImageContentType")() | Valid image content types supported by Arthur API | +| [`ImageResponseType`](arthurai.common.constants.ImageResponseType.html#arthurai.common.constants.ImageResponseType "arthurai.common.constants.ImageResponseType")() | Valid image response types supported by Arthur API | +| [`InputType`](arthurai.common.constants.InputType.html#arthurai.common.constants.InputType "arthurai.common.constants.InputType")() | | +| [`ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum")() | This class operates similar to Enum but passes mypy type checking. | +| [`OutputType`](arthurai.common.constants.OutputType.html#arthurai.common.constants.OutputType "arthurai.common.constants.OutputType")() | | +| [`Role`](arthurai.common.constants.Role.html#arthurai.common.constants.Role "arthurai.common.constants.Role")() | | +| [`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")() | | +| [`TextDelimiter`](arthurai.common.constants.TextDelimiter.html#arthurai.common.constants.TextDelimiter "arthurai.common.constants.TextDelimiter")() | This class contains patterns that can be used as text\_delimiter for NLP models. | +| [`ValueType`](arthurai.common.constants.ValueType.html#arthurai.common.constants.ValueType "arthurai.common.constants.ValueType")() | | + + + + + + + + +[Next + +arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) +[Previous + +arthurai.common](arthurai.common.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.arthur_excepted.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.arthur_excepted.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..dc7bd66113d466a5d1d16b2861e2f1184de6fe25 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.arthur_excepted.md.txt @@ -0,0 +1,410 @@ + + + + + + +arthurai.common.exceptions.arthur\_excepted - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](#) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.exceptions.arthur\_excepted[#](#arthurai-common-exceptions-arthur-excepted "Permalink to this headline") +======================================================================================================================== + + + + +arthurai.common.exceptions.arthur\_excepted(*message=None*)[#](#arthurai.common.exceptions.arthur_excepted "Permalink to this definition") +Decorator to wrap user-facing Arthur functions with exception handling that describes to the user whether the error +is their fault or is our fault and should be reported. +:param message: an optional message to prefix the error with, should describe the failure e.g. “failed to send +inferences” or “an error occurred while creating the model.” +:return: the decorator function + + + + + + + + +[Next + +arthurai.common.log](arthurai.common.log.html) +[Previous + +arthurai.common.exceptions](arthurai.common.exceptions.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7d503b7818fa563aac3fb93855a943c589289aa2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.exceptions.md.txt @@ -0,0 +1,438 @@ + + + + + + +arthurai.common.exceptions - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](#)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.exceptions[#](#module-arthurai.common.exceptions "Permalink to this headline") +============================================================================================== + + +Functions + + + + + + + + +| [`arthur\_excepted`](arthurai.common.exceptions.arthur_excepted.html#arthurai.common.exceptions.arthur_excepted "arthurai.common.exceptions.arthur_excepted")([message]) | Decorator to wrap user-facing Arthur functions with exception handling that describes to the user whether the error is their fault or is our fault and should be reported. | + + + +Exceptions + + + + + + + + +| `ArthurError` | Base Error for Arthur SDK. | +| `ArthurInternalError` | Exception raised when user input is correct but an error occurs. | +| `ArthurUserError` | Exception raised due to incorrect user input to the Arthur SDK. | +| `ExpectedParameterNotFoundError` | Exception raised when a field or property should be available from Arthur but is unexpectedly missing. | +| `ForbiddenError` | Exception raised when a 403 Forbidden response is received from the API. | +| `InternalTypeError` | Exception raised when a value is unexpected. | +| `InternalValueError` | Exception raised when a value is unexpected. | +| `MethodNotApplicableError` | Exception raised when the method called is not valid for the resource. | +| `MissingParameterError` | Exception raised when parameters supplied to the Arthur SDK are missing. | +| `ResponseClientError` | Exception raised when a 4XX response is received from the API. | +| `ResponseRedirectError` | Exception raised when a 3XX response is unexpectedly received from the API. | +| `ResponseServerError` | Exception raised when a 5XX response is received from the API. | +| `UserTypeError` | Exception raised when a user supplies an argument of the incorrect type to the Arthur SDK. | +| `UserValueError` | Exception raised when a user supplies an invalid value to the Arthur SDK. | + + + + + + + + +[Next + +arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) +[Previous + +arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.log.InfoFilter.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.log.InfoFilter.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..35938f4d5359af42a421ded0ad22fe16529b65cb --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.log.InfoFilter.md.txt @@ -0,0 +1,433 @@ + + + + + + +arthurai.common.log.InfoFilter - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](#) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.log.InfoFilter[#](#arthurai-common-log-infofilter "Permalink to this headline") +=============================================================================================== + + + + +*class* arthurai.common.log.InfoFilter(*name=''*)[#](#arthurai.common.log.InfoFilter "Permalink to this definition") +Bases: `logging.Filter` + + +A logging filter to only log messages that are debug or info level (i.e. never log warning or error messages) + + +Methods + + + + + + + + +| [`filter`](#arthurai.common.log.InfoFilter.filter "arthurai.common.log.InfoFilter.filter") | Determine if the specified record is to be logged. | + + + + + +filter(*rec*)[#](#arthurai.common.log.InfoFilter.filter "Permalink to this definition") +Determine if the specified record is to be logged. + + +Returns True if the record should be logged, or False otherwise. +If deemed appropriate, the record may be modified in-place. + + + + + + + + + +[Next + +arthurai.core](arthurai.core.html) +[Previous + +arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.log.disable_debug_logging.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.log.disable_debug_logging.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..8b331f46ff80868a44cacdaab2a97662e18864a5 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.log.disable_debug_logging.md.txt @@ -0,0 +1,407 @@ + + + + + + +arthurai.common.log.disable\_debug\_logging - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](#) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.log.disable\_debug\_logging[#](#arthurai-common-log-disable-debug-logging "Permalink to this headline") +======================================================================================================================= + + + + +arthurai.common.log.disable\_debug\_logging()[#](#arthurai.common.log.disable_debug_logging "Permalink to this definition") +Disables debug logging for the arthurai package. Note that log messages may be dropped while this function is +being executed. + + + + + + + + +[Next + +arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) +[Previous + +arthurai.common.log](arthurai.common.log.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.log.enable_debug_logging.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.log.enable_debug_logging.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6768723a851fb6ced3377d64ab0fdf9fa26b52f8 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.log.enable_debug_logging.md.txt @@ -0,0 +1,407 @@ + + + + + + +arthurai.common.log.enable\_debug\_logging - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](#) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.log.enable\_debug\_logging[#](#arthurai-common-log-enable-debug-logging "Permalink to this headline") +===================================================================================================================== + + + + +arthurai.common.log.enable\_debug\_logging()[#](#arthurai.common.log.enable_debug_logging "Permalink to this definition") +Enables debug logging for the arthurai package. Note that log messages may be dropped while this function is +being executed. + + + + + + + + +[Next + +arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) +[Previous + +arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.log.initialize_logging.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.log.initialize_logging.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..564f32b9098bc9b44c2d130e07a0f60318826890 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.log.initialize_logging.md.txt @@ -0,0 +1,406 @@ + + + + + + +arthurai.common.log.initialize\_logging - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](#) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.log.initialize\_logging[#](#arthurai-common-log-initialize-logging "Permalink to this headline") +================================================================================================================ + + + + +arthurai.common.log.initialize\_logging()[#](#arthurai.common.log.initialize_logging "Permalink to this definition") +Creates a parent ‘arthurai’ logger with a console output and INFO level. + + + + + + + + +[Next + +arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) +[Previous + +arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.log.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.log.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..bfd4fd993b04fc982d8a32640516a9eaf45d02ef --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.log.md.txt @@ -0,0 +1,441 @@ + + + + + + +arthurai.common.log - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](#)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common.log[#](#module-arthurai.common.log "Permalink to this headline") +================================================================================ + + +Functions + + + + + + + + +| [`disable\_debug\_logging`](arthurai.common.log.disable_debug_logging.html#arthurai.common.log.disable_debug_logging "arthurai.common.log.disable_debug_logging")() | Disables debug logging for the arthurai package. | +| [`enable\_debug\_logging`](arthurai.common.log.enable_debug_logging.html#arthurai.common.log.enable_debug_logging "arthurai.common.log.enable_debug_logging")() | Enables debug logging for the arthurai package. | +| [`initialize\_logging`](arthurai.common.log.initialize_logging.html#arthurai.common.log.initialize_logging "arthurai.common.log.initialize_logging")() | Creates a parent 'arthurai' logger with a console output and INFO level. | + + + +Classes + + + + + + + + +| [`InfoFilter`](arthurai.common.log.InfoFilter.html#arthurai.common.log.InfoFilter "arthurai.common.log.InfoFilter")([name]) | A logging filter to only log messages that are debug or info level (i.e. | + + + + + + + + +[Next + +arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) +[Previous + +arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + On this page + + + + +* [arthurai.common.log](#) + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.common.md.txt b/files/arthur-docs-markdown/sdk/arthurai.common.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..f5f17d0dc6f66eaf1f37b3b9a3d7166ec610eecf --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.common.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai.common - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](#)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.common[#](#module-arthurai.common "Permalink to this headline") +======================================================================== + + +Constants, exceptions, and logging for use in other packages + + + + + + + + +| [`arthurai.common.constants`](arthurai.common.constants.html#module-arthurai.common.constants "arthurai.common.constants") | | +| [`arthurai.common.exceptions`](arthurai.common.exceptions.html#module-arthurai.common.exceptions "arthurai.common.exceptions") | | +| [`arthurai.common.log`](arthurai.common.log.html#module-arthurai.common.log "arthurai.common.log") | | + + + + + + + + +[Next + +arthurai.common.constants](arthurai.common.constants.html) +[Previous + +arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Alert.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Alert.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..943b390d789d894a99dd2b0ce89b093b138bd7db --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Alert.md.txt @@ -0,0 +1,522 @@ + + + + + + +arthurai.core.alerts.Alert - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](#) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.Alert[#](#arthurai-core-alerts-alert "Permalink to this headline") +======================================================================================= + + + + +*class* arthurai.core.alerts.Alert(*id*, *timestamp*, *metric\_value*, *message*, *model\_id*, *status*, *alert\_rule*, *window\_start=None*, *window\_end=None*, *batch\_id=None*)[#](#arthurai.core.alerts.Alert "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.alerts.Alert.clean_nones "arthurai.core.alerts.Alert.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.alerts.Alert.to_dict "arthurai.core.alerts.Alert.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.alerts.Alert.to_json "arthurai.core.alerts.Alert.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `batch\_id` | | +| `dataclass\_json\_config` | | +| `window\_end` | | +| `window\_start` | | +| `id` | | +| `timestamp` | | +| `metric\_value` | | +| `message` | | +| `model\_id` | | +| `status` | | +| `alert\_rule` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.alerts.Alert.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.alerts.Alert.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.alerts.Alert.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) +[Previous + +arthurai.core.alerts](arthurai.core.alerts.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRule.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRule.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..c39ea6ca64400e49d7f87bc422ca34d1c9676040 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRule.md.txt @@ -0,0 +1,522 @@ + + + + + + +arthurai.core.alerts.AlertRule - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](#) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.AlertRule[#](#arthurai-core-alerts-alertrule "Permalink to this headline") +=============================================================================================== + + + + +*class* arthurai.core.alerts.AlertRule(*bound*, *threshold*, *metric\_id*, *severity*, *name=None*, *lookback\_period=None*, *subsequent\_alert\_wait\_time=None*, *enabled=True*, *id=None*, *metric\_name=None*)[#](#arthurai.core.alerts.AlertRule "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.alerts.AlertRule.clean_nones "arthurai.core.alerts.AlertRule.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.alerts.AlertRule.to_dict "arthurai.core.alerts.AlertRule.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.alerts.AlertRule.to_json "arthurai.core.alerts.AlertRule.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `dataclass\_json\_config` | | +| `enabled` | | +| `id` | | +| `lookback\_period` | | +| `metric\_name` | | +| `name` | | +| `subsequent\_alert\_wait\_time` | | +| `bound` | | +| `threshold` | | +| `metric\_id` | | +| `severity` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.alerts.AlertRule.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.alerts.AlertRule.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.alerts.AlertRule.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) +[Previous + +arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleBound.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleBound.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d86a8ca4625081ad7ac5dfdaa9262bad94770eac --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleBound.md.txt @@ -0,0 +1,440 @@ + + + + + + +arthurai.core.alerts.AlertRuleBound - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](#) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.AlertRuleBound[#](#arthurai-core-alerts-alertrulebound "Permalink to this headline") +========================================================================================================= + + + + +*class* arthurai.core.alerts.AlertRuleBound[#](#arthurai.core.alerts.AlertRuleBound "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.core.alerts.AlertRuleBound.list "arthurai.core.alerts.AlertRuleBound.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Lower` | | +| `Upper` | | + + + + + +*classmethod* list()[#](#arthurai.core.alerts.AlertRuleBound.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) +[Previous + +arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleSeverity.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleSeverity.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..0b0e467ea826cb6032fdd111da6ff3067b7cb3d9 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertRuleSeverity.md.txt @@ -0,0 +1,440 @@ + + + + + + +arthurai.core.alerts.AlertRuleSeverity - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](#) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.AlertRuleSeverity[#](#arthurai-core-alerts-alertruleseverity "Permalink to this headline") +=============================================================================================================== + + + + +*class* arthurai.core.alerts.AlertRuleSeverity[#](#arthurai.core.alerts.AlertRuleSeverity "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.core.alerts.AlertRuleSeverity.list "arthurai.core.alerts.AlertRuleSeverity.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Critical` | | +| `Warning` | | + + + + + +*classmethod* list()[#](#arthurai.core.alerts.AlertRuleSeverity.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) +[Previous + +arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertStatus.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertStatus.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..06d4af2ff4c719303c98cbd37b5958b3925c16e2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.AlertStatus.md.txt @@ -0,0 +1,440 @@ + + + + + + +arthurai.core.alerts.AlertStatus - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](#) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.AlertStatus[#](#arthurai-core-alerts-alertstatus "Permalink to this headline") +=================================================================================================== + + + + +*class* arthurai.core.alerts.AlertStatus[#](#arthurai.core.alerts.AlertStatus "Permalink to this definition") +Bases: [`arthurai.common.constants.ListableStrEnum`](arthurai.common.constants.ListableStrEnum.html#arthurai.common.constants.ListableStrEnum "arthurai.common.constants.ListableStrEnum") + + +Methods + + + + + + + + +| [`list`](#arthurai.core.alerts.AlertStatus.list "arthurai.core.alerts.AlertStatus.list") | Lists all attributes in alphabetical order | + + + +Attributes + + + + + + + + +| `Acknowledged` | | +| `Resolved` | | + + + + + +*classmethod* list()[#](#arthurai.core.alerts.AlertStatus.list "Permalink to this definition") +Lists all attributes in alphabetical order + + + + + + + + + +[Next + +arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) +[Previous + +arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Metric.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Metric.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ee88558f58dfdfd0d5dce3be479fe14161b34430 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.Metric.md.txt @@ -0,0 +1,518 @@ + + + + + + +arthurai.core.alerts.Metric - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](#) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts.Metric[#](#arthurai-core-alerts-metric "Permalink to this headline") +========================================================================================= + + + + +*class* arthurai.core.alerts.Metric(*id*, *name*, *query*, *is\_default*, *type=None*, *attribute=None*)[#](#arthurai.core.alerts.Metric "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.alerts.Metric.clean_nones "arthurai.core.alerts.Metric.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.alerts.Metric.to_dict "arthurai.core.alerts.Metric.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.alerts.Metric.to_json "arthurai.core.alerts.Metric.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `attribute` | | +| `dataclass\_json\_config` | | +| `type` | | +| `id` | | +| `name` | | +| `query` | | +| `is\_default` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.alerts.Metric.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.alerts.Metric.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.alerts.Metric.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) +[Previous + +arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.alerts.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..95fd3b3350f2462cb26dfd4053e4be14c35fabdc --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.alerts.md.txt @@ -0,0 +1,418 @@ + + + + + + +arthurai.core.alerts - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](#)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.alerts[#](#module-arthurai.core.alerts "Permalink to this headline") +================================================================================== + + +Classes + + + + + + + + +| [`Alert`](arthurai.core.alerts.Alert.html#arthurai.core.alerts.Alert "arthurai.core.alerts.Alert")(id, timestamp, metric\_value, message, ...) | | +| [`AlertRule`](arthurai.core.alerts.AlertRule.html#arthurai.core.alerts.AlertRule "arthurai.core.alerts.AlertRule")(bound, threshold, metric\_id, severity) | | +| [`AlertRuleBound`](arthurai.core.alerts.AlertRuleBound.html#arthurai.core.alerts.AlertRuleBound "arthurai.core.alerts.AlertRuleBound")() | | +| [`AlertRuleSeverity`](arthurai.core.alerts.AlertRuleSeverity.html#arthurai.core.alerts.AlertRuleSeverity "arthurai.core.alerts.AlertRuleSeverity")() | | +| [`AlertStatus`](arthurai.core.alerts.AlertStatus.html#arthurai.core.alerts.AlertStatus "arthurai.core.alerts.AlertStatus")() | | +| [`Metric`](arthurai.core.alerts.Metric.html#arthurai.core.alerts.Metric "arthurai.core.alerts.Metric")(id, name, query, is\_default[, type, ...]) | | +| [`MetricType`](arthurai.core.alerts.MetricType.html#arthurai.core.alerts.MetricType "arthurai.core.alerts.MetricType")() | | + + + + + + + + +[Next + +arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) +[Previous + +arthurai.core](arthurai.core.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeBin.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeBin.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2a761275a957172dcb232ff30e5e360be610ef7f --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeBin.md.txt @@ -0,0 +1,520 @@ + + + + + + +arthurai.core.attributes.AttributeBin - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](#) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.attributes.AttributeBin[#](#arthurai-core-attributes-attributebin "Permalink to this headline") +============================================================================================================= + + + + +*class* arthurai.core.attributes.AttributeBin(*continuous\_start=None*, *continuous\_end=None*)[#](#arthurai.core.attributes.AttributeBin "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + + +A list of the attribute’s bins. An attribute will only have bins if it is not categorical. The bin start isexclusive and the end is inclusive, (continuous\_start, continuous\_end]. Use Null to represent an open end of a bin. + + + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.attributes.AttributeBin.clean_nones "arthurai.core.attributes.AttributeBin.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.attributes.AttributeBin.to_dict "arthurai.core.attributes.AttributeBin.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.attributes.AttributeBin.to_json "arthurai.core.attributes.AttributeBin.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `continuous\_end` | | +| `continuous\_start` | | +| `dataclass\_json\_config` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.attributes.AttributeBin.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.attributes.AttributeBin.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.attributes.AttributeBin.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) +[Previous + +arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeCategory.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeCategory.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..de80c4441571e8d1ae7d104fadd01cbecb5d8c31 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.AttributeCategory.md.txt @@ -0,0 +1,517 @@ + + + + + + +arthurai.core.attributes.AttributeCategory - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](#) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.attributes.AttributeCategory[#](#arthurai-core-attributes-attributecategory "Permalink to this headline") +======================================================================================================================= + + + + +*class* arthurai.core.attributes.AttributeCategory(*value*, *label=None*)[#](#arthurai.core.attributes.AttributeCategory "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +A list of the attribute’s categories. An attribute will only have categories if it is marked as categorical. + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.attributes.AttributeCategory.clean_nones "arthurai.core.attributes.AttributeCategory.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.attributes.AttributeCategory.to_dict "arthurai.core.attributes.AttributeCategory.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.attributes.AttributeCategory.to_json "arthurai.core.attributes.AttributeCategory.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `dataclass\_json\_config` | | +| `label` | | +| `value` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.attributes.AttributeCategory.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.attributes.AttributeCategory.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.attributes.AttributeCategory.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.auth\_info](arthurai.core.auth_info.html) +[Previous + +arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.attributes.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e647273b0ea206996ec5a295048a1bbb76a3d0e1 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.attributes.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai.core.attributes - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](#)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.attributes[#](#module-arthurai.core.attributes "Permalink to this headline") +========================================================================================== + + +Classes + + + + + + + + +| [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")(name, value\_type, stage[, ...]) | ArthurAttribute encapsulates data associated with a model attribute | +| [`AttributeBin`](arthurai.core.attributes.AttributeBin.html#arthurai.core.attributes.AttributeBin "arthurai.core.attributes.AttributeBin")([continuous\_start, continuous\_end]) | A list of the attribute's bins. An attribute will only have bins if it is not categorical. The bin start is | +| [`AttributeCategory`](arthurai.core.attributes.AttributeCategory.html#arthurai.core.attributes.AttributeCategory "arthurai.core.attributes.AttributeCategory")(value[, label]) | A list of the attribute's categories. | + + + + + + + + +[Next + +arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) +[Previous + +arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.auth_info.AuthInfo.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.auth_info.AuthInfo.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..64647b8bafb5af7a81887fb04e7f7787557ecff3 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.auth_info.AuthInfo.md.txt @@ -0,0 +1,521 @@ + + + + + + +arthurai.core.auth\_info.AuthInfo - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](#) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.auth\_info.AuthInfo[#](#arthurai-core-auth-info-authinfo "Permalink to this headline") +==================================================================================================== + + + + +*class* arthurai.core.auth\_info.AuthInfo(*issuer*, *username*, *first\_name*, *last\_name*, *email*, *roles*, *organization\_ids*, *internal\_user\_id=None*, *external\_user\_id=None*)[#](#arthurai.core.auth_info.AuthInfo "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.auth_info.AuthInfo.clean_nones "arthurai.core.auth_info.AuthInfo.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.auth_info.AuthInfo.to_dict "arthurai.core.auth_info.AuthInfo.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.auth_info.AuthInfo.to_json "arthurai.core.auth_info.AuthInfo.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `dataclass\_json\_config` | | +| `external\_user\_id` | | +| `internal\_user\_id` | | +| `issuer` | | +| `username` | | +| `first\_name` | | +| `last\_name` | | +| `email` | | +| `roles` | | +| `organization\_ids` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.auth_info.AuthInfo.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.auth_info.AuthInfo.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.auth_info.AuthInfo.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.base](arthurai.core.base.html) +[Previous + +arthurai.core.auth\_info](arthurai.core.auth_info.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.base.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.base.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6520725e177f5d082b180870a55f2f0acfa32221 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.base.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.base - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](#)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.base[#](#module-arthurai.core.base "Permalink to this headline") +============================================================================== + + +Classes + + + + + + + + +| [`ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass")() | | + + + + + + + + +[Next + +arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) +[Previous + +arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.BiasMetrics.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.BiasMetrics.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7bcf96fa07da40314046ebd06ae74d2f62b0d517 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.BiasMetrics.md.txt @@ -0,0 +1,495 @@ + + + + + + +arthurai.core.bias.bias\_metrics.BiasMetrics - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](#) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.bias\_metrics.BiasMetrics[#](#arthurai-core-bias-bias-metrics-biasmetrics "Permalink to this headline") +========================================================================================================================== + + + + +*class* arthurai.core.bias.bias\_metrics.BiasMetrics(*arthur\_model*)[#](#arthurai.core.bias.bias_metrics.BiasMetrics "Permalink to this definition") +Bases: `object` + + +Methods + + + + + + + + +| [`demographic\_parity`](#arthurai.core.bias.bias_metrics.BiasMetrics.demographic_parity "arthurai.core.bias.bias_metrics.BiasMetrics.demographic_parity") | Get group-conditional positivity rates for all inferences, with the option to filter for a batch\_id or a particular chunk of time. | +| [`group\_confusion\_matrices`](#arthurai.core.bias.bias_metrics.BiasMetrics.group_confusion_matrices "arthurai.core.bias.bias_metrics.BiasMetrics.group_confusion_matrices") | Get group-conditional confusion matrices for all inferences, with the option to filter for a batch\_id or a particular chunk of time. | +| [`group\_positivity\_rates`](#arthurai.core.bias.bias_metrics.BiasMetrics.group_positivity_rates "arthurai.core.bias.bias_metrics.BiasMetrics.group_positivity_rates") | Get group-conditional positivity rates for all inferences, with the option to filter for a batch\_id or a particular chunk of time. | + + + + + +demographic\_parity(*attr\_name*, *batch\_id=None*, *start\_time=None*, *end\_time=None*)[#](#arthurai.core.bias.bias_metrics.BiasMetrics.demographic_parity "Permalink to this definition") +Get group-conditional positivity rates for all inferences, with the option to filter for a batch\_id or +a particular chunk of time. Currently only supports calculating bias with respect to a single sensitive +attribute at a time. This method currently only handles binary models. + + + +Parameters +* **attr\_name** (`str`) – The name of the sensitive attribute to get metrics for. +* **batch\_id** (`Optional`[`str`]) – Optional filter to limit calculations to a specific batch ID. +* **start\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences after a specific timestamp. +* **end\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences before a specific timestamp. + + + +Returns +A dict of the form {sens\_1: pos\_1, sens\_2: pos\_2, …} + + + + + + + +group\_confusion\_matrices(*attr\_name*, *pred\_property=None*, *batch\_id=None*, *start\_time=None*, *end\_time=None*, *return\_by\_metric=True*)[#](#arthurai.core.bias.bias_metrics.BiasMetrics.group_confusion_matrices "Permalink to this definition") +Get group-conditional confusion matrices for all inferences, with the option to filter for a batch\_id or +a particular chunk of time. Currently only supports calculating bias with respect to a single sensitive +attribute at a time. This method handles both binary and multiclass models. + + + +Parameters +* **attr\_name** (`str`) – The name of the sensitive attribute to get metrics for. +* **pred\_property** (`Optional`[`str`]) – For multiclass models, the predicted label to get the confusion matrix for. +* **batch\_id** (`Optional`[`str`]) – Optional filter to limit calculations to a specific batch ID. +* **start\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences after a specific timestamp. +* **end\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences before a specific timestamp. +* **return\_by\_metric** – Whether the returned dictionary of results should be keyed by metric or by sensitive attribute value. + + + +Returns +Either a dict of the form { metric: { sens\_1: val1, sens\_2: val2 }, …} (default) or its reverse. + + + + + + + +group\_positivity\_rates(*attr\_name*, *batch\_id=None*, *start\_time=None*, *end\_time=None*)[#](#arthurai.core.bias.bias_metrics.BiasMetrics.group_positivity_rates "Permalink to this definition") +Get group-conditional positivity rates for all inferences, with the option to filter for a batch\_id or +a particular chunk of time. Currently only supports calculating bias with respect to a single sensitive +attribute at a time. This method currently only handles binary models. + + + +Parameters +* **attr\_name** (`str`) – The name of the sensitive attribute to get metrics for. +* **batch\_id** (`Optional`[`str`]) – Optional filter to limit calculations to a specific batch ID. +* **start\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences after a specific timestamp. +* **end\_time** (`Optional`[`datetime`]) – Optional filter to limit calculations to inferences before a specific timestamp. + + + +Returns +A dict of the form {sens\_1: pos\_1, sens\_2: pos\_2, …} + + + + + + + + + + + +[Next + +arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html) +[Previous + +arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..177eda451f8dd3935d805958730342131863d612 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_metrics.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.bias.bias\_metrics - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](#)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.bias\_metrics[#](#module-arthurai.core.bias.bias_metrics "Permalink to this headline") +========================================================================================================= + + +Classes + + + + + + + + +| [`BiasMetrics`](arthurai.core.bias.bias_metrics.BiasMetrics.html#arthurai.core.bias.bias_metrics.BiasMetrics "arthurai.core.bias.bias_metrics.BiasMetrics")(arthur\_model) | | + + + + + + + + +[Next + +arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) +[Previous + +arthurai.core.bias](arthurai.core.bias.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2e2121217a3ce4dbb40e0fe3316081cb61b6980d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.md.txt @@ -0,0 +1,423 @@ + + + + + + +arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](#) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper[#](#arthurai-core-bias-bias-wrapper-arthurbiaswrapper "Permalink to this headline") +====================================================================================================================================== + + + + +*class* arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper(*arthur\_model*)[#](#arthurai.core.bias.bias_wrapper.ArthurBiasWrapper "Permalink to this definition") +Bases: `object` + + +This is a wrapper class for all bias-related functionality, including metrics +and mitigation. This allows users to access bias functionality directly from the +ArthurModel object: arthur\_model.bias.metrics, for example. + + +Methods + + + + + + + + + + + + + + + + + +[Next + +arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html) +[Previous + +arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..b240e97428fa437eba10e2ec947e1f61ffb21216 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.bias_wrapper.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.bias.bias\_wrapper - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](#)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.bias\_wrapper[#](#module-arthurai.core.bias.bias_wrapper "Permalink to this headline") +========================================================================================================= + + +Classes + + + + + + + + +| [`ArthurBiasWrapper`](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html#arthurai.core.bias.bias_wrapper.ArthurBiasWrapper "arthurai.core.bias.bias_wrapper.ArthurBiasWrapper")(arthur\_model) | This is a wrapper class for all bias-related functionality, including metrics and mitigation. | + + + + + + + + +[Next + +arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) +[Previous + +arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..fc2facc626503130fd50a2f4db76862f6e46144d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.md.txt @@ -0,0 +1,411 @@ + + + + + + +arthurai.core.bias - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](#)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias[#](#module-arthurai.core.bias "Permalink to this headline") +============================================================================== + + + + + + + + +| [`arthurai.core.bias.bias\_metrics`](arthurai.core.bias.bias_metrics.html#module-arthurai.core.bias.bias_metrics "arthurai.core.bias.bias_metrics") | | +| [`arthurai.core.bias.bias\_wrapper`](arthurai.core.bias.bias_wrapper.html#module-arthurai.core.bias.bias_wrapper "arthurai.core.bias.bias_wrapper") | | +| [`arthurai.core.bias.threshold\_mitigation`](arthurai.core.bias.threshold_mitigation.html#module-arthurai.core.bias.threshold_mitigation "arthurai.core.bias.threshold_mitigation") | | + + + + + + + + +[Next + +arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html) +[Previous + +arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.Curves.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.Curves.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a9f8e162582c70ceebe82111bf12f1e30aa84ec0 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.Curves.md.txt @@ -0,0 +1,439 @@ + + + + + + +arthurai.core.bias.threshold\_mitigation.Curves - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](#) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.threshold\_mitigation.Curves[#](#arthurai-core-bias-threshold-mitigation-curves "Permalink to this headline") +================================================================================================================================ + + + + +*class* arthurai.core.bias.threshold\_mitigation.Curves(*attribute\_name*, *constraint*, *max\_acc\_idx*, *attr\_val\_to\_threshold*)[#](#arthurai.core.bias.threshold_mitigation.Curves "Permalink to this definition") +Bases: `object` + + +A class which defines information about a given set of curves for a specific sensitive +attribute and a specific constraint, as well as a dictionary mapping attribute values +to the curves themselves + + +Methods + + + + + + + + + + + +Attributes + + + + + + + + +| `attribute\_name` | | +| `constraint` | | +| `max\_acc\_idx` | | +| `attr\_val\_to\_threshold` | | + + + + + + + + + +[Next + +arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) +[Previous + +arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.ThresholdMitigation.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.ThresholdMitigation.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..c0546c83fa8621b1951def8fbfa5470df0402e9f --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.ThresholdMitigation.md.txt @@ -0,0 +1,485 @@ + + + + + + +arthurai.core.bias.threshold\_mitigation.ThresholdMitigation - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](#) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.threshold\_mitigation.ThresholdMitigation[#](#arthurai-core-bias-threshold-mitigation-thresholdmitigation "Permalink to this headline") +========================================================================================================================================================== + + + + +*class* arthurai.core.bias.threshold\_mitigation.ThresholdMitigation(*arthur\_model*)[#](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation "Permalink to this definition") +Bases: `object` + + +Methods + + + + + + + + +| [`enable`](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.enable "arthurai.core.bias.threshold_mitigation.ThresholdMitigation.enable") | Triggers workflow to train curves for all constraints and for all sensitive attributes. | +| [`get\_curves`](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_curves "arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_curves") | Fetch curves for the given sensitive attribute and constraint. | +| [`get\_thresholds\_for\_idx`](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_thresholds_for_idx "arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_thresholds_for_idx") | Retrieve the thresholds for each group, given a set of curves and aparticular optimization index. | +| [`plot\_curves`](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.plot_curves "arthurai.core.bias.threshold_mitigation.ThresholdMitigation.plot_curves") | Simple plot of the tradeoff curve for a single sensitive attribute and constraint. | + + + + + +enable()[#](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.enable "Permalink to this definition") +Triggers workflow to train curves for all constraints and for all sensitive attributes. +Equivalent to calling arthurmodel.enable\_bias\_mitigation(); here for convenience. + + + + + +get\_curves(*attribute*, *constraint='equal\_opportunity'*)[#](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_curves "Permalink to this definition") +Fetch curves for the given sensitive attribute and constraint. + + + +Parameters +* **attribute** (`str`) – Name of the sensitive attribute to fetch curves for. +* **constraint** (`str`) – which constraint to use. “demographic\_parity”, “equal\_opportunity”, or “equalized\_odds” + + + +Returns +a Curves object which contains information about the attribute, constraint, accuracy-maximizing index, +and the actual curves. + + + + + + + +get\_thresholds\_for\_idx(*curves*, *idx=None*)[#](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.get_thresholds_for_idx "Permalink to this definition") +Retrieve the thresholds for each group, given a set of curves and aparticular optimization index. + + + +Parameters +* **curves** ([`Curves`](arthurai.core.bias.threshold_mitigation.Curves.html#arthurai.core.bias.threshold_mitigation.Curves "arthurai.core.bias.threshold_mitigation.Curves")) – one Curves object containing a set of curves corresponding to a single sensitive attribute and constraint. +* **idx** (`Optional`[`int`]) – one integer (between 0 and 1000, inclusive) that represents a specific solution option. Defaults to the curve’s accuracy-maximizing index. + + + +Returns +a dictionary mapping sensitive feature values to the prediction threshold used for that group. + + + + + + + +plot\_curves(*curves=None*, *attribute=None*, *constraint=None*)[#](#arthurai.core.bias.threshold_mitigation.ThresholdMitigation.plot_curves "Permalink to this definition") +Simple plot of the tradeoff curve for a single sensitive attribute and constraint. + + + +Parameters +**curves** (`Optional`[[`Curves`](arthurai.core.bias.threshold_mitigation.Curves.html#arthurai.core.bias.threshold_mitigation.Curves "arthurai.core.bias.threshold_mitigation.Curves")]) – one Curves object containing a set of curves corresponding to a single sensitive attribute and constraint. + + + + + + + + + + + +[Next + +arthurai.core.data\_service](arthurai.core.data_service.html) +[Previous + +arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6a5f8eaaa1dc02dab2c447017ff264cc54330851 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.bias.threshold_mitigation.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.core.bias.threshold\_mitigation - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](#)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.bias.threshold\_mitigation[#](#module-arthurai.core.bias.threshold_mitigation "Permalink to this headline") +========================================================================================================================= + + +Classes + + + + + + + + +| [`Curves`](arthurai.core.bias.threshold_mitigation.Curves.html#arthurai.core.bias.threshold_mitigation.Curves "arthurai.core.bias.threshold_mitigation.Curves")(attribute\_name, constraint, ...) | A class which defines information about a given set of curves for a specific sensitive attribute and a specific constraint, as well as a dictionary mapping attribute values to the curves themselves | +| [`ThresholdMitigation`](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html#arthurai.core.bias.threshold_mitigation.ThresholdMitigation "arthurai.core.bias.threshold_mitigation.ThresholdMitigation")(arthur\_model) | | + + + + + + + + +[Next + +arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) +[Previous + +arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.data_service.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.data_service.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6c2d38693af008a209c39b23e8d62131332a20cd --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.data_service.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.core.data\_service - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](#)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.data\_service[#](#module-arthurai.core.data_service "Permalink to this headline") +=============================================================================================== + + +Classes + + + + + + + + +| [`DatasetService`](arthurai.core.data_service.DatasetService.html#arthurai.core.data_service.DatasetService "arthurai.core.data_service.DatasetService")() | | +| [`ImageZipper`](arthurai.core.data_service.ImageZipper.html#arthurai.core.data_service.ImageZipper "arthurai.core.data_service.ImageZipper")() | | + + + + + + + + +[Next + +arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) +[Previous + +arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.decorators.log_prediction.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.decorators.log_prediction.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..6c323dffa6f0f365cb0bad3e2621bce75408f6fe --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.decorators.log_prediction.md.txt @@ -0,0 +1,435 @@ + + + + + + +arthurai.core.decorators.log\_prediction - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](#) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.decorators.log\_prediction[#](#arthurai-core-decorators-log-prediction "Permalink to this headline") +================================================================================================================== + + + + +arthurai.core.decorators.log\_prediction(*arthur\_model*)[#](#arthurai.core.decorators.log_prediction "Permalink to this definition") +Decorator to log the inputs and prediction of a model to Arthur. + + + +Parameters +**arthur\_model** ([`ArthurModel`](arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel "arthurai.core.models.ArthurModel")) – A previously-saved ArthurModel object + + + + +Note, the prediction function to be decorated can take optional arguments for logging; +these should be passed as kwargs into the function to be decorated. + + + +Parameters +* **inference\_timestamp** – A timestamp in ISO 8601 format +* **partner\_inference\_id** – A unique identifier for an inference + + + +Return type +`Callable`[[`Any`], `Any`] + + + +Returns +Tuple of (model\_prediction, inference\_id) + + + + + + + + + + +[Next + +arthurai.core.inferences](arthurai.core.inferences.html) +[Previous + +arthurai.core.decorators](arthurai.core.decorators.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.decorators.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.decorators.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7f22c184c3fc4ad698a37c15d0da520d5e03c9cb --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.decorators.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.decorators - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](#)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.decorators[#](#module-arthurai.core.decorators "Permalink to this headline") +========================================================================================== + + +Functions + + + + + + + + +| [`log\_prediction`](arthurai.core.decorators.log_prediction.html#arthurai.core.decorators.log_prediction "arthurai.core.decorators.log_prediction")(arthur\_model) | Decorator to log the inputs and prediction of a model to Arthur. | + + + + + + + + +[Next + +arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) +[Previous + +arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_inference_metadata_to_dataframe.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_inference_metadata_to_dataframe.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..511e9c63d228196177f9de3c7c9072e8fd14c371 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_inference_metadata_to_dataframe.md.txt @@ -0,0 +1,431 @@ + + + + + + +arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](#) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe[#](#arthurai-core-inferences-add-inference-metadata-to-dataframe "Permalink to this headline") +=============================================================================================================================================================== + + + + +arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe(*df*, *model\_attributes*, *ignore\_join\_errors=False*)[#](#arthurai.core.inferences.add_inference_metadata_to_dataframe "Permalink to this definition") +Adds timestamp and/or partner\_inference\_id fields to the DataFrame. + + + +Parameters +* **df** (`DataFrame`) – DataFrame to add metadata to +* **model\_attributes** (`Collection`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")]) – attributes of the model +* **ignore\_join\_errors** (`bool`) – if True, allow inference data without `partner\_inference\_id` or ground truth data + + + +Return type +`DataFrame` + + + +Returns +the input DataFrame if no updates are needed, otherwise a shallow copy with the new columns + + + +Raises +**UserValueError** – if inference data is supplied without `partner\_inference\_id` or ground truth data, and +`ignore\_join\_errors` is False. + + + + + + + + + + +[Next + +arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) +[Previous + +arthurai.core.inferences](arthurai.core.inferences.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_predictions_or_ground_truth.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_predictions_or_ground_truth.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..627228292861b32c981f87ae87ae6a830977c7ee --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.add_predictions_or_ground_truth.md.txt @@ -0,0 +1,416 @@ + + + + + + +arthurai.core.inferences.add\_predictions\_or\_ground\_truth - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](#) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.inferences.add\_predictions\_or\_ground\_truth[#](#arthurai-core-inferences-add-predictions-or-ground-truth "Permalink to this headline") +======================================================================================================================================================= + + + + +arthurai.core.inferences.add\_predictions\_or\_ground\_truth(*inference\_data*, *new\_data*, *attributes*, *stage*)[#](#arthurai.core.inferences.add_predictions_or_ground_truth "Permalink to this definition") +Add prediction or ground truth data to inference data *in place*. +:type inference\_data: `List`[`Dict`[`str`, `Any`]] +:param inference\_data: the inference data as a List of Dicts as expected by the Arthur API +:type new\_data: `Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`, `Iterable`[`Any`]] +:param new\_data: the new data to add in, as a List of Dicts, Dict of Lists, DataFrame, or Sequence +(if a single column) +:type attributes: `List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] +:param attributes: the model’s attributes +:type stage: [`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") +:param stage: the Stage of the new data, either PredictedValue or GroundTruth +:return: None (modifies inference\_data in place) + + + + + + + + +[Next + +arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) +[Previous + +arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.inferences.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..7b8700493ec8ca49b1e6084755bfea5d87e37b5d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.md.txt @@ -0,0 +1,415 @@ + + + + + + +arthurai.core.inferences - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](#)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.inferences[#](#module-arthurai.core.inferences "Permalink to this headline") +========================================================================================== + + +Functions + + + + + + + + +| [`add\_inference\_metadata\_to\_dataframe`](arthurai.core.inferences.add_inference_metadata_to_dataframe.html#arthurai.core.inferences.add_inference_metadata_to_dataframe "arthurai.core.inferences.add_inference_metadata_to_dataframe")(df, ...) | Adds timestamp and/or partner\_inference\_id fields to the DataFrame. | +| [`add\_predictions\_or\_ground\_truth`](arthurai.core.inferences.add_predictions_or_ground_truth.html#arthurai.core.inferences.add_predictions_or_ground_truth "arthurai.core.inferences.add_predictions_or_ground_truth")(...) | Add prediction or ground truth data to inference data *in place*. | +| [`nest\_inference\_and\_ground\_truth\_data`](arthurai.core.inferences.nest_inference_and_ground_truth_data.html#arthurai.core.inferences.nest_inference_and_ground_truth_data "arthurai.core.inferences.nest_inference_and_ground_truth_data")(data, ...) | Reformat List of Dicts inference data to nest inference and ground truth data as expected by the Arthur API. | +| [`parse\_stage\_attributes`](arthurai.core.inferences.parse_stage_attributes.html#arthurai.core.inferences.parse_stage_attributes "arthurai.core.inferences.parse_stage_attributes")(data, attributes, stage) | Parses data for a single stage into the standard List of Dicts format. | + + + + + + + + +[Next + +arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) +[Previous + +arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.inferences.parse_stage_attributes.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.parse_stage_attributes.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d3b4e5bd02d0da97fd412891679100ee2b82f465 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.inferences.parse_stage_attributes.md.txt @@ -0,0 +1,431 @@ + + + + + + +arthurai.core.inferences.parse\_stage\_attributes - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](#) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.inferences.parse\_stage\_attributes[#](#arthurai-core-inferences-parse-stage-attributes "Permalink to this headline") +=================================================================================================================================== + + + + +arthurai.core.inferences.parse\_stage\_attributes(*data*, *attributes*, *stage*)[#](#arthurai.core.inferences.parse_stage_attributes "Permalink to this definition") +Parses data for a single stage into the standard List of Dicts format. + + +If the stage contains only a single attribute, data can be a single list-like column. + + + +See also + + +Similar to dataframe\_like\_to\_list\_of\_dicts, but an expected column (attribute)-aware and supports single columns + + + + +Parameters +* **data** (`Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`, `Iterable`[`Any`]]) – +* **attributes** (`List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")]) – +* **stage** ([`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")) – + + + +Returns +parsed data in List of Dicts formt + + + + + + + + + + +[Next + +arthurai.core.model\_utils](arthurai.core.model_utils.html) +[Previous + +arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..559036ba98ae9170e8afb4f250da299ae7f9afe5 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.md.txt @@ -0,0 +1,423 @@ + + + + + + +arthurai.core - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](#)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core[#](#module-arthurai.core "Permalink to this headline") +==================================================================== + + +Primary ArthurAI functionality + + + + + + + + +| [`arthurai.core.alerts`](arthurai.core.alerts.html#module-arthurai.core.alerts "arthurai.core.alerts") | | +| [`arthurai.core.attributes`](arthurai.core.attributes.html#module-arthurai.core.attributes "arthurai.core.attributes") | | +| [`arthurai.core.auth\_info`](arthurai.core.auth_info.html#module-arthurai.core.auth_info "arthurai.core.auth_info") | | +| [`arthurai.core.base`](arthurai.core.base.html#module-arthurai.core.base "arthurai.core.base") | | +| [`arthurai.core.bias`](arthurai.core.bias.html#module-arthurai.core.bias "arthurai.core.bias") | | +| [`arthurai.core.data\_service`](arthurai.core.data_service.html#module-arthurai.core.data_service "arthurai.core.data_service") | | +| [`arthurai.core.decorators`](arthurai.core.decorators.html#module-arthurai.core.decorators "arthurai.core.decorators") | | +| [`arthurai.core.inferences`](arthurai.core.inferences.html#module-arthurai.core.inferences "arthurai.core.inferences") | | +| [`arthurai.core.model\_utils`](arthurai.core.model_utils.html#module-arthurai.core.model_utils "arthurai.core.model_utils") | | +| [`arthurai.core.models`](arthurai.core.models.html#module-arthurai.core.models "arthurai.core.models") | | +| [`arthurai.core.util`](arthurai.core.util.html#module-arthurai.core.util "arthurai.core.util") | | +| [`arthurai.core.viz`](arthurai.core.viz.html#module-arthurai.core.viz "arthurai.core.viz") | | + + + + + + + + +[Next + +arthurai.core.alerts](arthurai.core.alerts.html) +[Previous + +arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.check_has_bias_attrs.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.check_has_bias_attrs.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..343c3a962479766424c0a938ef03e7a7ad4e88c0 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.check_has_bias_attrs.md.txt @@ -0,0 +1,406 @@ + + + + + + +arthurai.core.model\_utils.check\_has\_bias\_attrs - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](#) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.model\_utils.check\_has\_bias\_attrs[#](#arthurai-core-model-utils-check-has-bias-attrs "Permalink to this headline") +=================================================================================================================================== + + + + +arthurai.core.model\_utils.check\_has\_bias\_attrs(*model*)[#](#arthurai.core.model_utils.check_has_bias_attrs "Permalink to this definition") +Returns True if and only if the model has any attributes being monitored for bias by Arthur + + + + + + + + +[Next + +arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) +[Previous + +arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.get_positive_predicted_class.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.get_positive_predicted_class.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..38440f6da9fc08483ca28c59c7d6d7d6dc45e5e9 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.get_positive_predicted_class.md.txt @@ -0,0 +1,407 @@ + + + + + + +arthurai.core.model\_utils.get\_positive\_predicted\_class - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](#) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.model\_utils.get\_positive\_predicted\_class[#](#arthurai-core-model-utils-get-positive-predicted-class "Permalink to this headline") +=================================================================================================================================================== + + + + +arthurai.core.model\_utils.get\_positive\_predicted\_class(*model*)[#](#arthurai.core.model_utils.get_positive_predicted_class "Permalink to this definition") +Checks if model is a binary classifier. Returns False if multiclass, otherwise returns the name of the positive +predicted attribute + + + + + + + + +[Next + +arthurai.core.models](arthurai.core.models.html) +[Previous + +arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..84c63a36018406736f91f8493cea125a025f4e47 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.model_utils.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai.core.model\_utils - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](#)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.model\_utils[#](#module-arthurai.core.model_utils "Permalink to this headline") +============================================================================================= + + +Functions + + + + + + + + +| [`check\_attr\_is\_bias`](arthurai.core.model_utils.check_attr_is_bias.html#arthurai.core.model_utils.check_attr_is_bias "arthurai.core.model_utils.check_attr_is_bias")(model, attr\_name) | Returns True if and only if the model has an attribute with the given name attr\_name being monitored for bias by Arthur | +| [`check\_has\_bias\_attrs`](arthurai.core.model_utils.check_has_bias_attrs.html#arthurai.core.model_utils.check_has_bias_attrs "arthurai.core.model_utils.check_has_bias_attrs")(model) | Returns True if and only if the model has any attributes being monitored for bias by Arthur | +| [`get\_positive\_predicted\_class`](arthurai.core.model_utils.get_positive_predicted_class.html#arthurai.core.model_utils.get_positive_predicted_class "arthurai.core.model_utils.get_positive_predicted_class")(model) | Checks if model is a binary classifier. | + + + + + + + + +[Next + +arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) +[Previous + +arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.models.ArthurModel.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.models.ArthurModel.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3d06a9939f4ce760dd99d942cb0eeeefdd095b54 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.models.ArthurModel.md.txt @@ -0,0 +1,3390 @@ + + + + + + +arthurai.core.models.ArthurModel - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](#) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.models.ArthurModel[#](#arthurai-core-models-arthurmodel "Permalink to this headline") +=================================================================================================== + + + + +*class* arthurai.core.models.ArthurModel(*partner\_model\_id*, *input\_type*, *output\_type*, *client=None*, *explainability=None*, *id=None*, *display\_name=None*, *description=None*, *is\_batch=False*, *archived=False*, *created\_at=None*, *updated\_at=None*, *attributes=None*, *tags=None*, *classifier\_threshold=None*, *text\_delimiter=None*, *expected\_throughput\_gb\_per\_day=None*, *pixel\_height=None*, *pixel\_width=None*, *image\_class\_labels=None*, *reference\_dataframe=None*, *model\_group\_id=None*, *version\_sequence\_num=None*, *version\_label=None*)[#](#arthurai.core.models.ArthurModel "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Arthur Model class represents the metadata which represents a registered model in the application + + + +Parameters +* **client** – `arthurai.client.Client` object which manages data storage +* **partner\_model\_id** – Client provided unique id to associate with the model. This field must be unique across +all active models cannot be changed once set. +* **input\_type** – [`arthurai.common.constants.InputType`](arthurai.common.constants.InputType.html#arthurai.common.constants.InputType "arthurai.common.constants.InputType") representing the model’s input data type. +* **output\_type** – [`arthurai.common.constants.InputType`](arthurai.common.constants.InputType.html#arthurai.common.constants.InputType "arthurai.common.constants.InputType") representing the model’s output data format. +* **explainability** – [`arthurai.core.models.ExplainabilityParameters`](arthurai.core.models.ExplainabilityParameters.html#arthurai.core.models.ExplainabilityParameters "arthurai.core.models.ExplainabilityParameters") object representing parameters that +will be used to create inference explanations. +* **id** – The auto-generated unique UUID for the model. Will be overwritten if set by the user. +* **display\_name** – An optional display name for the model. +* **description** – Optional description of the model. +* **is\_batch** – Boolean value to determine whether the model sends inferences in batch or streaming format. +Defaults to False. +* **archived** – Indicates whether or not a model has been archived, defaults to false. +* **created\_at** – UTC timestamp in ISO8601 format of when the model was created. Will be overwritten if set by the +user. +* **updated\_at** – UTC timestamp in ISO8601 format of when the model was last updated. Will be overwritten if set by +the user. +* **attributes** – List of [`arthurai.core.attributes.ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute") objects registered to the model +* **tags** – List of string keywords to associate with the model. +* **classifier\_thresholds** – Threshold value for classification models, default is 0.5. +* **text\_delimiter** – Only valid for models with input\_type equal to +`arthurai.common.constants.InputType.NLP`. Represents the text delimiter +to divide input strings. +* **expected\_throughput\_gb\_per\_day** – Expected amount of throughput. +* **pixel\_height** – Only valid for models with input\_type equal to +`arthurai.common.constants.InputType.Image`. Expected image height in pixels. +* **pixel\_width** – Only valid for models with input\_type equal to +`arthurai.common.constants.InputType.Image`. Expected image width in pixels. + + + + +Methods + + + + + + + + +| [`add\_attribute`](#arthurai.core.models.ArthurModel.add_attribute "arthurai.core.models.ArthurModel.add_attribute") | Adds a new attribute of stage ModelPipelineInput or NonInputData to the model. | +| [`add\_binary\_classifier\_output\_attributes`](#arthurai.core.models.ArthurModel.add_binary_classifier_output_attributes "arthurai.core.models.ArthurModel.add_binary_classifier_output_attributes") | Registers GroundTruth and PredictedValue attributes and their thresholds | +| [`add\_classifier\_output\_attributes\_gtclass`](#arthurai.core.models.ArthurModel.add_classifier_output_attributes_gtclass "arthurai.core.models.ArthurModel.add_classifier_output_attributes_gtclass") | Registers ground truth and predicted value attributes for classification models | +| [`add\_image\_attribute`](#arthurai.core.models.ArthurModel.add_image_attribute "arthurai.core.models.ArthurModel.add_image_attribute") | Wraps add\_attribute for images (see [`ArthurModel.add\_attribute()`](#arthurai.core.models.ArthurModel.add_attribute "arthurai.core.models.ArthurModel.add_attribute")) | +| [`add\_multiclass\_classifier\_output\_attributes`](#arthurai.core.models.ArthurModel.add_multiclass_classifier_output_attributes "arthurai.core.models.ArthurModel.add_multiclass_classifier_output_attributes") | Registers GroundTruth and PredictedValue attributes | +| [`add\_object\_detection\_output\_attributes`](#arthurai.core.models.ArthurModel.add_object_detection_output_attributes "arthurai.core.models.ArthurModel.add_object_detection_output_attributes") | Registers ground truth and predicted value attributes for an object detection model, as well as setting the image class labels. | +| [`add\_regression\_output\_attributes`](#arthurai.core.models.ArthurModel.add_regression_output_attributes "arthurai.core.models.ArthurModel.add_regression_output_attributes") | Registers ground truth attributes and predicted value attributes for regression models. | +| [`archive`](#arthurai.core.models.ArthurModel.archive "arthurai.core.models.ArthurModel.archive") | Archives the model with a DELETE request | +| [`binarize`](#arthurai.core.models.ArthurModel.binarize "arthurai.core.models.ArthurModel.binarize") | Creates a binary class probability based on classes defined in a `ModelType.Multiclass` model | +| [`build`](#arthurai.core.models.ArthurModel.build "arthurai.core.models.ArthurModel.build") | Build an Arthur model from a Pandas DataFrame, inferring the attribute metadata and registering the reference data to be stored with Arthur. | +| [`check\_attr\_is\_bias`](#arthurai.core.models.ArthurModel.check_attr_is_bias "arthurai.core.models.ArthurModel.check_attr_is_bias") | Returns True if and only if the model has an attribute with the given name attr\_name being monitored for bias by Arthur | +| [`check\_has\_bias\_attrs`](#arthurai.core.models.ArthurModel.check_has_bias_attrs "arthurai.core.models.ArthurModel.check_has_bias_attrs") | Returns True if and only if the model has any attributes being monitored for bias by Arthur | +| [`clean\_nones`](#arthurai.core.models.ArthurModel.clean_nones "arthurai.core.models.ArthurModel.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| [`close\_batch`](#arthurai.core.models.ArthurModel.close_batch "arthurai.core.models.ArthurModel.close_batch") | Closes the specified batch, optionally can supply the number of inferences that are contained in the batch | +| [`create\_alert\_rule`](#arthurai.core.models.ArthurModel.create_alert_rule "arthurai.core.models.ArthurModel.create_alert_rule") | Creates alert rules for the current model. | +| [`create\_metric`](#arthurai.core.models.ArthurModel.create_metric "arthurai.core.models.ArthurModel.create_metric") | Creates a metric registered to this model and returns the UUID assigned to the newly created metric. | +| [`delete\_explainer`](#arthurai.core.models.ArthurModel.delete_explainer "arthurai.core.models.ArthurModel.delete_explainer") | Spin down the model explainability server | +| [`enable\_bias\_mitigation`](#arthurai.core.models.ArthurModel.enable_bias_mitigation "arthurai.core.models.ArthurModel.enable_bias_mitigation") | Updates the bias mitigation Enrichment to be enabled | +| [`enable\_explainability`](#arthurai.core.models.ArthurModel.enable_explainability "arthurai.core.models.ArthurModel.enable_explainability") | Enable explainability for this model. | +| [`enable\_hotspots`](#arthurai.core.models.ArthurModel.enable_hotspots "arthurai.core.models.ArthurModel.enable_hotspots") | Updates the hotspots Enrichment to be enabled | +| [`explain\_inference`](#arthurai.core.models.ArthurModel.explain_inference "arthurai.core.models.ArthurModel.explain_inference") | Returns feature importance scores for each attribute of stage ModelPipelineInput | +| [`find\_hotspots`](#arthurai.core.models.ArthurModel.find_hotspots "arthurai.core.models.ArthurModel.find_hotspots") | Retrieve hotspots from the model | +| [`from\_dataframe`](#arthurai.core.models.ArthurModel.from_dataframe "arthurai.core.models.ArthurModel.from_dataframe") | Auto-generate attributes based on input data | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| [`get\_alert\_rules`](#arthurai.core.models.ArthurModel.get_alert_rules "arthurai.core.models.ArthurModel.get_alert_rules") | Returns a paginated list of alert rules registered to this model | +| [`get\_alerts`](#arthurai.core.models.ArthurModel.get_alerts "arthurai.core.models.ArthurModel.get_alerts") | Returns a paginated list of alert registered to this model. | +| [`get\_attribute`](#arthurai.core.models.ArthurModel.get_attribute "arthurai.core.models.ArthurModel.get_attribute") | Retrieves an attribute by name and stage | +| [`get\_attribute\_names`](#arthurai.core.models.ArthurModel.get_attribute_names "arthurai.core.models.ArthurModel.get_attribute_names") | Returns a list of the names of attributes for the specified stage. | +| [`get\_attributes`](#arthurai.core.models.ArthurModel.get_attributes "arthurai.core.models.ArthurModel.get_attributes") | Returns a list of attributes for the specified stage. | +| [`get\_enrichment`](#arthurai.core.models.ArthurModel.get_enrichment "arthurai.core.models.ArthurModel.get_enrichment") | Returns configuration for the specified enrichment. | +| [`get\_enrichments`](#arthurai.core.models.ArthurModel.get_enrichments "arthurai.core.models.ArthurModel.get_enrichments") | Returns configuration for all enrichments. | +| [`get\_image`](#arthurai.core.models.ArthurModel.get_image "arthurai.core.models.ArthurModel.get_image") | Saves the image specified by image\_id to a file | +| [`get\_image\_attribute`](#arthurai.core.models.ArthurModel.get_image_attribute "arthurai.core.models.ArthurModel.get_image_attribute") | Returns the attribute with value\_type=Image for input\_type=Image models | +| [`get\_metrics`](#arthurai.core.models.ArthurModel.get_metrics "arthurai.core.models.ArthurModel.get_metrics") | Retrieves metrics associated with the current model. | +| [`get\_positive\_predicted\_class`](#arthurai.core.models.ArthurModel.get_positive_predicted_class "arthurai.core.models.ArthurModel.get_positive_predicted_class") | Checks if model is a binary classifier. | +| [`infer\_schema`](#arthurai.core.models.ArthurModel.infer_schema "arthurai.core.models.ArthurModel.infer_schema") | Auto-generate attributes based on input data | +| [`model\_is\_saved`](#arthurai.core.models.ArthurModel.model_is_saved "arthurai.core.models.ArthurModel.model_is_saved") | Returns True if and only if the model has been saved to the Arthur platform | +| [`one\_hot\_encode`](#arthurai.core.models.ArthurModel.one_hot_encode "arthurai.core.models.ArthurModel.one_hot_encode") | Creates a one hot encoding of a class label based on classes defined in a `ModelType.Multiclass` model | +| [`query`](#arthurai.core.models.ArthurModel.query "arthurai.core.models.ArthurModel.query") | Execute query against the model's inferences. | +| [`remove\_attribute`](#arthurai.core.models.ArthurModel.remove_attribute "arthurai.core.models.ArthurModel.remove_attribute") | Removes an already-made ArthurAttribute from the model. | +| [`rename\_attribute`](#arthurai.core.models.ArthurModel.rename_attribute "arthurai.core.models.ArthurModel.rename_attribute") | Renames an attribute by name and stage | +| [`review`](#arthurai.core.models.ArthurModel.review "arthurai.core.models.ArthurModel.review") | Prints a summary of the properties of all attributes in the model. | +| [`save`](#arthurai.core.models.ArthurModel.save "arthurai.core.models.ArthurModel.save") | Check and save this model | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`send\_batch\_ground\_truths`](#arthurai.core.models.ArthurModel.send_batch_ground_truths "arthurai.core.models.ArthurModel.send_batch_ground_truths") | +Deprecated since version 3.10.0. + | +| [`send\_batch\_inferences`](#arthurai.core.models.ArthurModel.send_batch_inferences "arthurai.core.models.ArthurModel.send_batch_inferences") | Send many inferences at once | +| [`send\_bulk\_ground\_truths`](#arthurai.core.models.ArthurModel.send_bulk_ground_truths "arthurai.core.models.ArthurModel.send_bulk_ground_truths") | Uploads a large batch of ground truth values to Arthur | +| [`send\_bulk\_inferences`](#arthurai.core.models.ArthurModel.send_bulk_inferences "arthurai.core.models.ArthurModel.send_bulk_inferences") | Uploads a large batch of inferences to Arthur | +| [`send\_inference`](#arthurai.core.models.ArthurModel.send_inference "arthurai.core.models.ArthurModel.send_inference") | +Deprecated since version 3.20.0. + | +| [`send\_inferences`](#arthurai.core.models.ArthurModel.send_inferences "arthurai.core.models.ArthurModel.send_inferences") | Send inferences to the Arthur API. | +| [`set\_attribute\_as\_sensitive`](#arthurai.core.models.ArthurModel.set_attribute_as_sensitive "arthurai.core.models.ArthurModel.set_attribute_as_sensitive") | Sets the passed-in attribute to be sensitive by setting attr.monitor\_for\_bias = True. | +| [`set\_attribute\_labels`](#arthurai.core.models.ArthurModel.set_attribute_labels "arthurai.core.models.ArthurModel.set_attribute_labels") | Sets labels for individual categories of a specific attribute | +| [`set\_predict\_function\_input\_order`](#arthurai.core.models.ArthurModel.set_predict_function_input_order "arthurai.core.models.ArthurModel.set_predict_function_input_order") | Sets the expected order of attributes used by the prediction function. | +| [`set\_reference\_data`](#arthurai.core.models.ArthurModel.set_reference_data "arthurai.core.models.ArthurModel.set_reference_data") | Validates and sets the reference data for the given stage to the provided data. | +| [`swap\_predicted\_attribute\_positions`](#arthurai.core.models.ArthurModel.swap_predicted_attribute_positions "arthurai.core.models.ArthurModel.swap_predicted_attribute_positions") | Swap the position of the model's two predicted attributes | +| [`to\_dict`](#arthurai.core.models.ArthurModel.to_dict "arthurai.core.models.ArthurModel.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.models.ArthurModel.to_json "arthurai.core.models.ArthurModel.to_json") | Creates a json representation of this object | +| [`update`](#arthurai.core.models.ArthurModel.update "arthurai.core.models.ArthurModel.update") | Update the current model object in the Arthur platform | +| [`update\_alert`](#arthurai.core.models.ArthurModel.update_alert "arthurai.core.models.ArthurModel.update_alert") | Updates alert to have a particular status. | +| [`update\_alert\_rule`](#arthurai.core.models.ArthurModel.update_alert_rule "arthurai.core.models.ArthurModel.update_alert_rule") | Updates alert rule fields included in the alert\_rule object for the specified alert rule id. | +| [`update\_enrichment`](#arthurai.core.models.ArthurModel.update_enrichment "arthurai.core.models.ArthurModel.update_enrichment") | Update the configuration for a single enrichment | +| [`update\_enrichments`](#arthurai.core.models.ArthurModel.update_enrichments "arthurai.core.models.ArthurModel.update_enrichments") | Update the configuration for 1 or more enrichments. | +| [`update\_inference\_ground\_truths`](#arthurai.core.models.ArthurModel.update_inference_ground_truths "arthurai.core.models.ArthurModel.update_inference_ground_truths") | Updates inferences with the supplied ground truth values | + + + +Attributes + + + + + + + + +| `archived` | | +| `attributes` | | +| `classifier\_threshold` | | +| `client` | | +| `created\_at` | | +| `dataclass\_json\_config` | | +| `description` | | +| `display\_name` | | +| `expected\_throughput\_gb\_per\_day` | | +| `explainability` | | +| [`ground\_truth\_type`](#arthurai.core.models.ArthurModel.ground_truth_type "arthurai.core.models.ArthurModel.ground_truth_type") | Returns GroundTruthClass if Arthur performed one-hot encoding in the creation of this model's current ground truth attribute. | +| `id` | | +| `image\_class\_labels` | | +| `is\_batch` | | +| `model\_group\_id` | | +| `pixel\_height` | | +| `pixel\_width` | | +| `reference\_dataframe` | | +| `tags` | | +| `text\_delimiter` | | +| `updated\_at` | | +| `version\_label` | | +| `version\_sequence\_num` | | +| `partner\_model\_id` | | +| `input\_type` | | +| `output\_type` | | + + + + + +add\_attribute(*name=None*, *value\_type=None*, *stage=None*, *label=None*, *position=None*, *categorical=False*, *min\_range=None*, *max\_range=None*, *monitor\_for\_bias=False*, *categories=None*, *bins=None*, *is\_unique=False*, *is\_positive\_predicted\_attribute=False*, *attribute\_link=None*, *arthur\_attribute=None*, *gt\_pred\_attrs\_map=None*)[#](#arthurai.core.models.ArthurModel.add_attribute "Permalink to this definition") +Adds a new attribute of stage ModelPipelineInput or NonInputData to the model. + + +For an introduction to attributes and stages, see + + +If you have built your model using arthur\_model.build(), your model attributes may already be inferred and you +do not need to add them with this function. + + +Formatting requirement: attribute names must contain only letters, numbers, and underscores, and cannot begin +with a number. + + + +``` +from arthurai.common.constants import Stage, ValueType + +# adds a float input attribute directly to the model +arthur\_model.add\_attribute( + name="attribute\_name", + value\_type=ValueType.Float, + stage=Stage.ModelPipelineInput +) + +``` + + + +Parameters +* **attribute\_link** (`Optional`[`str`]) – Only applicable for GroundTruth or PredictedValue staged attributes. +If stage is equal to GroundTruth, this represents the associated PredictedValue attribute and vice versa +* **is\_positive\_predicted\_attribute** (`bool`) – Only applicable for PredictedValue attributes on a Binary +Classification model. Should be set to True on the positive predicted value attribute. +* **is\_unique** (`bool`) – Boolean value used to signal if the values of this attribute are unique. +* **bins** (`Optional`[`List`[`Union`[`int`, `float`, [`AttributeBin`](arthurai.core.attributes.AttributeBin.html#arthurai.core.attributes.AttributeBin "arthurai.core.attributes.AttributeBin")]]]) – List of bin cut-offs used to discretize continuous attributes. Use None as an open ended value. +`[None, 18, 65, None]` represents the three following bins: `value < 18, 18 < value < 65, value > 65` +* **monitor\_for\_bias** (`bool`) – boolean value set to True if the attribute should be monitored for bias +* **max\_range** (`Union`[`int`, `float`, `None`]) – Max value for a continuous attribute +* **min\_range** (`Union`[`int`, `float`, `None`]) – Min value for a continuous attribute +* **categorical** (`bool`) – Boolean value set to True if the attribute has categorical values. +* **position** (`Optional`[`int`]) – The array position of attribute within the stage. Required in the PREDICT\_FUNCTION\_INPUT stage. +* **label** (`Optional`[`str`]) – Label for attribute. If attribute has an encoded name, a more readable label can be set. +* **stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – [`arthurai.common.constants.Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") of this attribute in the model pipeline +* **value\_type** (`Optional`[[`ValueType`](arthurai.common.constants.ValueType.html#arthurai.common.constants.ValueType "arthurai.common.constants.ValueType")]) – [`arthurai.common.constants.ValueType`](arthurai.common.constants.ValueType.html#arthurai.common.constants.ValueType "arthurai.common.constants.ValueType") associated with this attributes values +* **name** (`Optional`[`str`]) – Name of the attribute. Attribute names can only contain alpha-numeric characters and underscores +and cannot start with a number. +* **categories** (`Optional`[`List`[`Union`[`str`, [`AttributeCategory`](arthurai.core.attributes.AttributeCategory.html#arthurai.core.attributes.AttributeCategory "arthurai.core.attributes.AttributeCategory")]]]) – [Only for Categorical Attributes] If the attribute is categorical, this will contain the +attribute’s categories. It is required only if the categorical flag is set to true. +* **arthur\_attribute** (`Optional`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")]) – Optional ArthurAttribute to add to the model +* **gt\_pred\_attrs\_map** (`Optional`[`Dict`]) – + + +Deprecated since version version: 2.0.0 + + +Use ArthurModel.add\_[model\_type]\_output\_attributes() instead + + + +Return type +`List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +add\_binary\_classifier\_output\_attributes(*positive\_predicted\_attr*, *pred\_to\_ground\_truth\_map*, *threshold=0.5*)[#](#arthurai.core.models.ArthurModel.add_binary_classifier_output_attributes "Permalink to this definition") +Registers GroundTruth and PredictedValue attributes and their thresholds + + +For an introduction to attributes and stages, +see + + +This function will create a predicted value and ground truth attribute for each mapping specified in +pred\_to\_ground\_truth\_map. + + + +``` +# map PredictedValue attributes to their corresponding GroundTruth attributes +PRED\_TO\_GROUND\_TRUTH\_MAP = {'pred\_0' : 'gt\_0', + 'pred\_1' : 'gt\_1'} + +# add the ground truth and predicted attributes to the model +# specifying that the `pred\_1` attribute is the +# positive predicted attribute, which means it corresponds to the +# probability that the binary target attribute is 1 +arthur\_model.add\_binary\_classifier\_output\_attributes(positive\_predicted\_attr='pred\_1', + pred\_to\_ground\_truth\_map=PRED\_TO\_GROUND\_TRUTH\_MAP) + +``` + + +For binary models, GroundTruth is always an integer, and PredictedAttribute is always a float. +Additionally, PredictedAttribute is expected to be a probability (e.g. the output of a scikit-learn +model’s predict\_proba method), rather than a classification to 0/1. + + +This assumes that separate columns for predicted values and ground truth values have already been created, +and that they have both been broken into two separate (pseudo-onehot) columns: for example, the column +ground\_truth\_label becomes ground\_truth\_label=0 and ground\_truth\_label=1, and the column pred\_prob +becomes pred\_prob=0 and pred\_prob=1. The pandas function pd.get\_dummies() can be useful for reformatting +the ground truth column, but be sure that the datatype is specified correctly as an int. + + + +Parameters +* **positive\_predicted\_attr** (`str`) – string name of the predicted attribute to register as the positive predicted attribute +* **pred\_to\_ground\_truth\_map** (`Dict`[`str`, `str`]) – Map of predicted value attributes to their corresponding ground truth attribute names. +The names provided in the dictionary will be used to register the one-hot encoded +version of the attributes. For example: {‘pred\_0’: ‘gt\_0’, ‘pred\_1’: ‘gt\_1’}, +Ensure the ordering of items in this dictionary is an accurate +representation of how model predictions (probability vectors) will be generated. +* **threshold** (`float`) – Threshold to use for the classifier model, defaults to 0.5 + + + +Return type +`Dict`[`str`, [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +Mapping of added attributes string name -> ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +add\_classifier\_output\_attributes\_gtclass(*pred\_to\_ground\_truth\_class\_map*, *ground\_truth\_column*, *data*, *positive\_predicted\_attr=None*)[#](#arthurai.core.models.ArthurModel.add_classifier_output_attributes_gtclass "Permalink to this definition") +Registers ground truth and predicted value attributes for classification models + + +Registers a GroundTruthClass attribute. In addition, registers a predicted value attribute for each of the +model’s predicted values. + + +For an introduction to attributes and stages, +see + + +Create a predicted value attribute for each key in pred\_to\_ground\_truth\_class\_map and a ground truth class +attribute for the ground\_truth\_column. + + + +``` +# Map PredictedValue attribute to its corresponding GroundTruth attribute value. +# This tells Arthur that the `pred\_survived` column represents +# the probability that the ground truth column has the value 1 +PRED\_TO\_GROUND\_TRUTH\_MAP = { + "pred\_value": 1 +} + +# Add the ground truth and predicted attributes to the model, +# specifying which attribute represents ground truth and +# which attribute represents the predicted value. +arthur\_model.add\_classifier\_output\_attributes\_gtclass( + positive\_predicted\_attr = 'pred\_value', + pred\_to\_ground\_truth\_class\_map = PRED\_TO\_GROUND\_TRUTH\_MAP, + ground\_truth\_column = 'gt\_column' +) + +``` + + + +Parameters +* **pred\_to\_ground\_truth\_class\_map** (`Dict`[`str`, `Any`]) – map from predicted column names to corresponding ground truth values +* **ground\_truth\_column** (`str`) – column name of column in data holding the ground truth values +* **data** (`DataFrame`) – DataFrame containing ground truth column data +* **positive\_predicted\_attr** (`Optional`[`str`]) – string name of the predicted attribute to register as the positive predicted +attribute, if binary classification + + + + +return: Mapping of added attributes string name -> ArthurAttribute Object + + + +Return type +`Dict`[`str`, [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + + + + + +add\_image\_attribute(*name=None*)[#](#arthurai.core.models.ArthurModel.add_image_attribute "Permalink to this definition") +Wraps add\_attribute for images (see [`ArthurModel.add\_attribute()`](#arthurai.core.models.ArthurModel.add_attribute "arthurai.core.models.ArthurModel.add_attribute")) + + +Automatically sets the stage as ModelPipelineInput + + + +Return type +`List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +add\_multiclass\_classifier\_output\_attributes(*pred\_to\_ground\_truth\_map*)[#](#arthurai.core.models.ArthurModel.add_multiclass_classifier_output_attributes "Permalink to this definition") +Registers GroundTruth and PredictedValue attributes + + +For an introduction to attributes and stages, +see + + +This function will create a predicted value and +ground truth attribute for each mapping specified in pred\_to\_ground\_truth\_map. + + + +``` +# map PredictedValue attributes to their corresponding GroundTruth attributes +PRED\_TO\_GROUND\_TRUTH\_MAP = { + "dog": "dog\_gt", + "cat": "cat\_gt", + "horse": "horse\_gt" +} + +# add the ground truth and predicted attributes to the model +arthur\_model.add\_multiclass\_classifier\_output\_attributes( + pred\_to\_ground\_truth\_map = PRED\_TO\_GROUND\_TRUTH\_MAP +) + +``` + + + +Parameters +**pred\_to\_ground\_truth\_map** (`Dict`[`str`, `str`]) – Map of predicted value attributes to their corresponding ground truth attribute names. +The names provided in the dictionary will be used to register the one-hot encoded +version of the attributes. Ensure the ordering of items in this dictionary is an accurate +representation of how model predictions (probability vectors) will be generated. + + + +Return type +`Dict`[`str`, [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +Mapping of added attributes string name -> ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +add\_object\_detection\_output\_attributes(*predicted\_attr\_name*, *gt\_attr\_name*, *image\_class\_labels*)[#](#arthurai.core.models.ArthurModel.add_object_detection_output_attributes "Permalink to this definition") +Registers ground truth and predicted value attributes for an object detection model, as well as +setting the image class labels. + + +For a guide to onboarding object detection models, +see + + +This function will create a predicted value attribute and ground truth attribute using the names provided, +giving each a value type of Bounding Box. Image class labels are also set on the model object. The index +of each label in the list should correspond to a class\_id the model outputs. + + +Ex: image\_class\_labels = [‘cat’, ‘dog’, ‘person’] +So a bounding box with class\_id of 0 would have label ‘cat’, +class\_id of 1 would have label ‘dog’, and class\_id of 2 would have label ‘person’ + + + +``` +predicted\_attribute\_name = "objects\_detected" +ground\_truth\_attribute\_name = "label" +class\_labels = ['cat', 'dog', 'person'] + +arthur\_model.add\_object\_detection\_output\_attributes( + predicted\_attribute\_name, + ground\_truth\_attribute\_name, + class\_labels) + +``` + + + +Parameters +* **predicted\_attr\_name** (`str`) – The name of the predicted value attribute +* **gt\_attr\_name** (`str`) – The name of the ground truth attribute +* **image\_class\_labels** (`List`[`str`]) – The labels for each class the model can predict, ordered by their class\_id + + + +Return type +`Dict`[`str`, [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +Mapping of added attributes string name -> ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +add\_regression\_output\_attributes(*pred\_to\_ground\_truth\_map*, *value\_type*, *data=None*)[#](#arthurai.core.models.ArthurModel.add_regression_output_attributes "Permalink to this definition") +Registers ground truth attributes and predicted value attributes for regression models. + + +For an introduction to attributes and stages, see + + + +``` +from arthurai.common.constants import ValueType + +# map PredictedValue attributes to their corresponding GroundTruth attributes +PRED\_TO\_GROUND\_TRUTH\_MAP = { + "pred\_value": "gt\_value", +} + +# add the ground truth and predicted attributes to the model +arthur\_model.add\_regression\_output\_attributes( + pred\_to\_ground\_truth\_map = PRED\_TO\_GROUND\_TRUTH\_MAP, + value\_type = ValueType.Float +) + +``` + + + +Parameters +* **pred\_to\_ground\_truth\_map** (`Dict`[`str`, `str`]) – Map of predicted value attributes to their corresponding ground truth attribute names. +The names provided in the dictionary will be used to register the one-hot encoded +version of the attributes. +* **value\_type** ([`ValueType`](arthurai.common.constants.ValueType.html#arthurai.common.constants.ValueType "arthurai.common.constants.ValueType")) – Value type of regression model output attribute (usually either ValueType.Integer or ValueType.Float) +* **data** (`Optional`[`DataFrame`]) – a reference DataFrame to build the model from. This is optional since it is currently only used +to calculate the min\_range and max\_range values of the predicted + ground truth attributes. If data +is not passed, min\_range and max\_range are not set in the attributes + + + +Return type +`Dict`[`str`, [`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +Mapping of added attributes string name -> ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +archive()[#](#arthurai.core.models.ArthurModel.archive "Permalink to this definition") +Archives the model with a DELETE request + + + +Returns +the server response + + + +Raises +**Exception** – the model has no ID, or the model has not been archived + + + +Permissions +model delete + + + + + + + +binarize(*attribute\_value*)[#](#arthurai.core.models.ArthurModel.binarize "Permalink to this definition") +Creates a binary class probability based on classes defined in a `ModelType.Multiclass` model + + +This function is only valid for models with two PredictedValue attributes +which correspond to the positive and negative probabilities of a binary classifier + + + +``` +# creates a binary class probability +# evaluating the model's two predicted values against this value +model.binarize({'ground\_truth\_column' : value}) + +``` + + + +Parameters +**attribute\_value** – a mapping of the name of a predicted value attribute to its value + + + +Returns +A two-value dictionary with probabilities for both predicted classes. + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +build(*data*, *pred\_to\_ground\_truth\_map*, *positive\_predicted\_attr=None*, *non\_input\_columns=None*, *ground\_truth\_column=None*, *set\_reference\_data=True*)[#](#arthurai.core.models.ArthurModel.build "Permalink to this definition") +Build an Arthur model from a Pandas DataFrame, +inferring the attribute metadata and registering the reference data to be stored with Arthur. + + +For a quickstart guide to building an ArthurModel, see + + +The pred\_to\_ground\_truth\_map parameter tells Arthur how the predicted value attributes +relate to the ground truth attributes of your model. + + +This dictionary can be formatted two different ways: + + +1. a prediction column name to ground truth column name mapping passed to pred\_to\_ground\_truth\_map + + + +``` +# map PredictedValue attribute to its corresponding GroundTruth attribute +# this tells Arthur that the `pred\_value` column represents +# the predicted value corresponding to the +# ground truth values in the `gt\_column` column +PRED\_TO\_GROUND\_TRUTH\_MAP = {'pred\_value' : 'gt\_column'} + +arthur\_model.build(reference\_df, + pred\_to\_ground\_truth\_map=PRED\_TO\_GROUND\_TRUTH\_MAP) + +``` + + +2. a prediction column name to ground truth class value mapping passed to pred\_to\_ground\_truth\_map,plus the name of the column holding the ground truth class values passed to ground\_truth\_column + + + +``` +# map PredictedValue attribute to its corresponding GroundTruth attribute value +# this tells Arthur that the `pred\_value` column represents +# the probability that the GroundTruth attribute `gt\_column` = 1 +# which we indicate in arthur\_model.build() with the `ground\_truth\_column` parameter +PRED\_TO\_GROUND\_TRUTH\_MAP = {'pred\_value' : 1} + +arthur\_model.build(reference\_df, + ground\_truth\_column="gt\_column", + pred\_to\_ground\_truth\_map=PRED\_TO\_GROUND\_TRUTH\_MAP) + +``` + + +Note that this function will remove any previously existing attributes. Combines calls to +[`ArthurModel.infer\_schema()`](#arthurai.core.models.ArthurModel.infer_schema "arthurai.core.models.ArthurModel.infer_schema") and (if set\_reference\_data is True) +[`ArthurModel.set\_reference\_data()`](#arthurai.core.models.ArthurModel.set_reference_data "arthurai.core.models.ArthurModel.set_reference_data") + + + +Parameters +* **data** (`DataFrame`) – a reference DataFrame to build the model from +* **pred\_to\_ground\_truth\_map** (`Dict`[`str`, `Any`]) – a mapping from predicted column names to their corresponding ground truth +column names, or ground truth values in ground\_truth\_column +* **positive\_predicted\_attr** (`Optional`[`str`]) – name of the predicted attribute to register as the positive predicted +attribute +* **non\_input\_columns** (`Optional`[`List`[`str`]]) – list of columns that contain auxiliary data not directly passed into the model +* **set\_reference\_data** – if True, register the provided DataFrame as the model’s reference dataset +* **ground\_truth\_column** (`Optional`[`str`]) – a single column name containing ground truth labels. +must be used with pred to ground truth class map + + + +Return type +`DataFrame` + + + +Returns +a DataFrame summarizing the inferred types + + + + + + + +check\_attr\_is\_bias(*attr\_name*)[#](#arthurai.core.models.ArthurModel.check_attr_is_bias "Permalink to this definition") +Returns True if and only if the model has an attribute with the given name attr\_name being monitored for bias by +Arthur + + + + + +check\_has\_bias\_attrs()[#](#arthurai.core.models.ArthurModel.check_has_bias_attrs "Permalink to this definition") +Returns True if and only if the model has any attributes being monitored for bias by Arthur + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.models.ArthurModel.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +close\_batch(*batch\_id*, *num\_inferences=None*)[#](#arthurai.core.models.ArthurModel.close_batch "Permalink to this definition") +Closes the specified batch, optionally can supply the number of inferences that are contained in the batch + + + +Parameters +* **batch\_id** (`str`) – String batch\_id associated with the batch that will be closed +* **num\_inferences** (`Optional`[`int`]) – Optional number of inferences that are contained in the batch + + + +Return type +`Dict` + + + +Returns +Response of the batch close rest call + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + +create\_alert\_rule(*metric\_id*, *bound*, *threshold*, *severity*, *name=None*, *lookback\_period=None*, *subsequent\_alert\_wait\_time=None*)[#](#arthurai.core.models.ArthurModel.create_alert_rule "Permalink to this definition") +Creates alert rules for the current model. + + +For an introduction to alerts, see + + +For a guide to configuring alerts, see + + + +Parameters +* **metric\_id** (`str`) – unique id (UUID) of the metric to use to create an alert rule. +* **name** (`Optional`[`str`]) – A name for the alert rule, a default will be generated if this is not supplied. +* **bound** ([`AlertRuleBound`](arthurai.core.alerts.AlertRuleBound.html#arthurai.core.alerts.AlertRuleBound "arthurai.core.alerts.AlertRuleBound")) – Whether the alert is triggered crossing the threshold from above or below. Either AlertRuleBound.Upper or AlertRuleBound.Lower +* **threshold** (`Union`[`int`, `float`]) – Threshold value of the alert rule. When the metric crosses this threshold, the alert is triggered. +* **severity** ([`AlertRuleSeverity`](arthurai.core.alerts.AlertRuleSeverity.html#arthurai.core.alerts.AlertRuleSeverity "arthurai.core.alerts.AlertRuleSeverity")) – AlertRuleSeverity of the alert which gets triggered when the metric violates the threshold of +the alert rule. +* **lookback\_period** (`Union`[`int`, `float`, `None`]) – The lookback time or “window length” in minutes to use when calculating the alert rule +metric. For example, a lookback period of 5 minutes for an alert rule on average +prediction will calculate average prediction for the past 5 minutes in a rolling window +format. This will default to 5 minutes +* **subsequent\_alert\_wait\_time** (`Union`[`int`, `float`, `None`]) – If metric continues to pass threshold this is the time in minutes to wait +before triggering another alert. This defaults to 0. This does not need to +be set for batch alerts. + + + +Return type +[`AlertRule`](arthurai.core.alerts.AlertRule.html#arthurai.core.alerts.AlertRule "arthurai.core.alerts.AlertRule") + + + +Returns +the created alert rule + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +alert\_rule write + + + + + + + +create\_metric(*name*, *query*, *is\_data\_drift=False*)[#](#arthurai.core.models.ArthurModel.create_metric "Permalink to this definition") +Creates a metric registered to this model and returns the UUID assigned to the newly created metric. + + +This metric can be used to create alert rules on. + + +For an introduction to creating metrics for alert rules, +see + + + +Parameters +* **name** (`str`) – Name of the metric to create. +* **query** (`Dict`[`str`, `Any`]) – Query which makes up the metric +* **is\_data\_drift** (`bool`) – Boolean to signal whether this query is a data drift metric or not. + + + +Return type +`str` + + + +Returns +UUID of the newly created metric + + + +Permissions +metric\_query write + + + + + + + +delete\_explainer()[#](#arthurai.core.models.ArthurModel.delete_explainer "Permalink to this definition") +Spin down the model explainability server + + +After calling this function, explainability will have to be re-enabled +if you want to compute feature importance scores for your model. + + + +Return type +`None` + + + +Returns +the server response + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config write + + + + + + + +enable\_bias\_mitigation()[#](#arthurai.core.models.ArthurModel.enable_bias_mitigation "Permalink to this definition") +Updates the bias mitigation Enrichment to be enabled + + + +See also + + +This convenience function wraps [`ArthurModel.update\_enrichment()`](#arthurai.core.models.ArthurModel.update_enrichment "arthurai.core.models.ArthurModel.update_enrichment") + + + + +Permissions +enrichment\_config write + + + + + + + +enable\_explainability(*df=None*, *project\_directory=None*, *user\_predict\_function\_import\_path=None*, *streaming\_explainability\_enabled=True*, *requirements\_file='requirements.txt'*, *python\_version=None*, *sdk\_version='3.20.2'*, *model\_server\_num\_cpu=None*, *model\_server\_memory=None*, *model\_server\_max\_replicas=None*, *inference\_consumer\_num\_cpu=None*, *inference\_consumer\_memory=None*, *inference\_consumer\_thread\_pool\_size=None*, *inference\_consumer\_score\_percent=None*, *explanation\_nsamples=None*, *explanation\_algo=None*, *ignore\_dirs=None*)[#](#arthurai.core.models.ArthurModel.enable_explainability "Permalink to this definition") +Enable explainability for this model. + + + +Parameters +* **df** (`Optional`[`DataFrame`]) – a dataframe containing the `Stage.ModelPipelineInput` values for this model. Required +for non-image models. +* **project\_directory** (`Optional`[`str`]) – the name of the directory containing the model source code. Required. +* **user\_predict\_function\_import\_path** (`Optional`[`str`]) – the name of the file that implements or wraps the predict function. +Required. +* **streaming\_explainability\_enabled** (`Optional`[`bool`]) – Defaults to true. flag to turn on streaming explanations which will +explain every inference sent to the platform. If false, explanations will need to be manually generated for +each inference via the Arthur API. Set to false if worried about compute cost. +* **requirements\_file** (`str`) – the name of the file that contains the pip requirements (default: requirements.txt) +* **python\_version** (`Optional`[`str`]) – the python version (default: sys.version). Should be in the form of . +* **sdk\_version** (`str`) – the version of the sdk to initialize the model servier with +* **model\_server\_num\_cpu** (`Optional`[`str`]) – string number of CPUs to provide to model server docker container. If not +provided, 1 CPU is used. Specified in the format of Kubernetes CPU resources. ‘1’, ‘1.5’, ‘100m’, etc. +* **model\_server\_memory** (`Optional`[`str`]) – The amount of memory to allocate to the model server docker container. Provided +in the format of kubernetes memory resources “1Gi” or “500Mi” (default: None). +* **model\_server\_max\_replicas** (`Optional`[`int`]) – The max number of model servers to create +* **inference\_consumer\_num\_cpu** (`Optional`[`str`]) – string number of CPUs to provide to inference consumer docker container. +If not provided, 1 CPU is used. Specified in the format of Kubernetes CPU resources. ‘1’, ‘1.5’, ‘100m’, +etc. (default: ‘1’) +* **inference\_consumer\_memory** (`Optional`[`str`]) – The amount of memory to allocate to the model server docker container. +Provided in the format of kubernetes memory resources “1Gi” or “500Mi” (default: ‘1G’). +* **inference\_consumer\_thread\_pool\_size** (`Optional`[`int`]) – The number of inference consumer workers, this determines how +many requests to the model server can be made in parallel. Default of 5. If increasing, CPU should be +increased as well. +* **inference\_consumer\_score\_percent** (`Optional`[`float`]) – What percent of inferences should get scored. Should be a value +between 0.0 and 1.0. Default 1.0 (everything is scored) +* **explanation\_nsamples** (`Optional`[`int`]) – number of predictions to use in the explanation. For SHAP and LIME, the default is +2000. (default: None) +* **explanation\_algo** (`Optional`[`str`]) – the algorithm to use for explaining inferences. Valid values are ‘lime’ and ‘shap’. +Defaults to ‘lime’. +* **ignore\_dirs** (`Optional`[`List`[`str`]]) – a list of directories within the project\_directory that you do not want to include when +uploading the model. Path is relative to project\_directory. + + + +Return type +`Dict`[`str`, `Any`] + + + +Returns +response content + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config write + + + + + + + +enable\_hotspots()[#](#arthurai.core.models.ArthurModel.enable_hotspots "Permalink to this definition") +Updates the hotspots Enrichment to be enabled + + + +See also + + +This convenience function wraps [`ArthurModel.update\_enrichment()`](#arthurai.core.models.ArthurModel.update_enrichment "arthurai.core.models.ArthurModel.update_enrichment") + + + + +Permissions +enrichment\_config write + + + + + + + +explain\_inference(*partner\_inference\_id*, *algorithm='lime'*, *page=1*, *page\_size=500*, *n\_samples=None*, *sort=None*)[#](#arthurai.core.models.ArthurModel.explain_inference "Permalink to this definition") +Returns feature importance scores for each attribute of stage ModelPipelineInput + + + +Parameters +* **partner\_inference\_id** (`str`) – the ID attached to the inference +* **algorithm** (`str`) – the explanation algorithm (‘lime’ or ‘shap’) used to generate the feature importance scores +* **page** (`int`) – the number of batches to split the results into +* **page\_size** (`int`) – the maximum number of inferences in each batch if returning inferences in batches +* **n\_samples** (`Optional`[`int`]) – # local perturbations for explanation (if None, uses default from lime or shap) +* **sort** (`Optional`[`str`]) – option for the ordering of returned explanations + + + +Return type +`Dict`[`str`, `Any`] + + + +Returns +Upload status response in the following format: + + + +``` +{ + "explanation": [ + { + "algorithm": "shap", + "predicted\_attribute\_name": "class\_a", + "importance\_scores": [ + { + "attribute\_name": "feature\_a", + "explanation\_value": 0.12, + "tokens": [ + { + "token": "dog", + "position": 0, + "explanation\_value": 0.48 + } + ] + } + ] + } + ], + "expected\_value": [ + { + "predicted\_attribute\_name": "feature\_a", + "expected\_value": 0.12 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data read + + + + + + + +find\_hotspots(*metric='accuracy'*, *threshold=0.5*, *batch\_id=None*, *date=None*, *ref\_set\_id=None*)[#](#arthurai.core.models.ArthurModel.find_hotspots "Permalink to this definition") +Retrieve hotspots from the model + + +For an introduction to the hotspots Enrichment, +see + + + +Parameters +* **metric** ([`AccuracyMetric`](arthurai.common.constants.AccuracyMetric.html#arthurai.common.constants.AccuracyMetric "arthurai.common.constants.AccuracyMetric")) – accuracy metric used to filter hotspots tree by, defaults to “accuracy” +* **threshold** (`float`) – threshold for of performance metric used for filtering hotspots, defaults to 0.5 +* **batch\_id** (`Optional`[`str`]) – string id for the batch to find hotspots in, defaults to None +* **date** (`Optional`[`str`]) – string used to define date, defaults to None +* **ref\_set\_id** (`Optional`[`str`]) – string id for the reference set to find hotspots in, defaults to None + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data read + + + +Return type +`Dict`[`str`, `Any`] + + + + + + + +from\_dataframe(*data*, *stage*)[#](#arthurai.core.models.ArthurModel.from_dataframe "Permalink to this definition") +Auto-generate attributes based on input data + + + +Deprecated since version 3.12.0: Please use [`ArthurModel.infer\_schema()`](#arthurai.core.models.ArthurModel.infer_schema "arthurai.core.models.ArthurModel.infer_schema") to add fields from a DataFrame to a model. + + + +Note that this does *not* automatically set reference +data; this method only reads the passed-in data, and then infers attribute names, types, etc. and sets them up +within the ArthurModel. + + + +See also + + +To also set your data as reference data, see [`ArthurModel.build()`](#arthurai.core.models.ArthurModel.build "arthurai.core.models.ArthurModel.build") + + + +For PredictedValue and GroundTruth stages, use the correct add\_\_output\_attributes() method instead. + + + +Parameters +* **data** (`Union`[`DataFrame`, `Series`]) – the data to infer attribute metadata from +* **stage** ([`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")) – [`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") of the data + + + +Return type +`None` + + + +Returns +a DataFrame summarizing the inferred types + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +get\_alert\_rules(*page=1*, *page\_size=20*)[#](#arthurai.core.models.ArthurModel.get_alert_rules "Permalink to this definition") +Returns a paginated list of alert rules registered to this model + + +For an introduction to alerts, see + + +For a guide to configuring alerts, see + + + +Parameters +* **page** (`int`) – page of alert rules to retrieve, defaults to 1 +* **page\_size** (`int`) – number of alert rules to return per page, defaults to 20 + + + +Return type +`List`[[`AlertRule`](arthurai.core.alerts.AlertRule.html#arthurai.core.alerts.AlertRule "arthurai.core.alerts.AlertRule")] + + + +Returns +List of `arthurai.client.apiv3.AlertRule` objects + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +alert\_rule read + + + + + + + +get\_alerts(*page=1*, *page\_size=500*, *status=None*, *alert\_rule\_id=None*, *batch\_id=None*, *start\_time=None*, *end\_time=None*)[#](#arthurai.core.models.ArthurModel.get_alerts "Permalink to this definition") +Returns a paginated list of alert registered to this model. + + +For an introduction to alerts, see + + +For a guide to configuring alerts, see + + + +Parameters +* **page** (`int`) – page of alert rules to retrieve, defaults to 1 +* **page\_size** (`int`) – number of alert rules to return per page, defaults to 500 +* **status** (`Optional`[`str`]) – status of alert rule +* **alert\_rule\_id** (`Optional`[`str`]) – id of alert rule +* **batch\_id** (`Optional`[`str`]) – constrain returned alert rules to this batch id +* **start\_time** (`Optional`[`str`]) – constrain returned alert rules to after this time +* **end\_time** (`Optional`[`str`]) – constrain returned alert rules to before this time + + + +Return type +`List`[[`Alert`](arthurai.core.alerts.Alert.html#arthurai.core.alerts.Alert "arthurai.core.alerts.Alert")] + + + +Returns +List of `arthurai.client.apiv3.Alert` objects + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +alert read + + + + + + + +get\_attribute(*name*, *stage=None*)[#](#arthurai.core.models.ArthurModel.get_attribute "Permalink to this definition") +Retrieves an attribute by name and stage + + + +Parameters +* **name** (`str`) – string name of the attribute to retrieve +* **stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – Optional Stage of attribute to retrieve + + + +Return type +[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute") + + + +Returns +ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +get\_attribute\_names(*stage=None*)[#](#arthurai.core.models.ArthurModel.get_attribute_names "Permalink to this definition") +Returns a list of the names of attributes for the specified stage. If stage is not supplied the function +will return all attribute names. + + + +Parameters +**stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – [`arthurai.common.constants.Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") to filter by + + + +Return type +`List`[`str`] + + + +Returns +List of string attribute names + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +get\_attributes(*stage=None*)[#](#arthurai.core.models.ArthurModel.get_attributes "Permalink to this definition") +Returns a list of attributes for the specified stage. If stage is not supplied the function will return +all attributes. + + + +Parameters +**stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – [`arthurai.common.constants.Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") to filter by + + + +Return type +`List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")] + + + +Returns +List of `arthurai.attributes.ArthurAttribute` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +get\_enrichment(*enrichment*)[#](#arthurai.core.models.ArthurModel.get_enrichment "Permalink to this definition") +Returns configuration for the specified enrichment. + + +For an introduction to enrichments, see + + +For a guide to configuring enrichments, see + + + +Parameters +**enrichment** ([`Enrichment`](arthurai.common.constants.Enrichment.html#arthurai.common.constants.Enrichment "arthurai.common.constants.Enrichment")) – Enrichment constant + + + +Return type +`Dict`[`str`, `Any`] + + + +Returns +Enrichment config + + + +``` +{ + "enabled": true, + "config": { + "python\_version": "3.7", + "sdk\_version": "3.0.11", + "streaming\_explainability\_enabled": false, + "user\_predict\_function\_import\_path": "entrypoint", + "shap\_expected\_values": "[0.7674405187893311, 0.23255948121066888]", + "model\_server\_cpu": "2", + "model\_server\_memory": "1Gi", + "model\_server\_max\_replicas": "5", + "explanation\_nsamples": 1000, + "explanation\_algo": "lime", + "inference\_consumer\_cpu": "100m", + "inference\_consumer\_memory": "512Mi", + "inference\_consumer\_score\_percent": "1.0", + "inference\_consumer\_thread\_pool\_size": "1", + "service\_account\_id": "8231affb-c107-478e-a1b4-e24e7f1f6619" + } +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config read + + + + + + + +get\_enrichments()[#](#arthurai.core.models.ArthurModel.get_enrichments "Permalink to this definition") +Returns configuration for all enrichments. + + +For an introduction to enrichments, see + + +For a guide to configuring enrichments, see + + + +Return type +`Dict`[`str`, `Any`] + + + +Returns +Upload status response in the following format: + + + +``` +{ + "anomaly\_detection": { + "enabled": false + }, + "explainability": { + "config": { + "python\_version": "3.7", + "sdk\_version": "3.0.11", + "streaming\_explainability\_enabled": false, + "user\_predict\_function\_import\_path": "entrypoint", + "shap\_expected\_values": "[0.7674405187893311, 0.23255948121066888]", + "model\_server\_cpu": "2", + "model\_server\_memory": "1Gi", + "model\_server\_max\_replicas": "5", + "explanation\_nsamples": 1000, + "explanation\_algo": "lime", + "inference\_consumer\_cpu": "100m", + "inference\_consumer\_memory": "512Mi", + "inference\_consumer\_score\_percent": "1.0", + "inference\_consumer\_thread\_pool\_size": "1", + "service\_account\_id": "8231affb-c107-478e-a1b4-e24e7f1f6619" + }, + "enabled": true + } +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config read + + + + + + + +get\_image(*image\_id*, *save\_path*, *type='raw\_image'*)[#](#arthurai.core.models.ArthurModel.get_image "Permalink to this definition") +Saves the image specified by image\_id to a file + + + +Parameters +* **image\_id** (`str`) – id of image in model +* **save\_path** (`str`) – directory to save the downloaded image to +* **type** ([`ImageResponseType`](arthurai.common.constants.ImageResponseType.html#arthurai.common.constants.ImageResponseType "arthurai.common.constants.ImageResponseType")) – type of response data + + + +Return type +`str` + + + +Returns +location of downloaded image file + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data read + + + + + + + +get\_image\_attribute()[#](#arthurai.core.models.ArthurModel.get_image_attribute "Permalink to this definition") +Returns the attribute with value\_type=Image for input\_type=Image models + + + +Return type +[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute") + + + +Returns +ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +get\_metrics(*default\_metrics=False*, *metric\_type=None*, *metric\_id=None*, *metric\_name=None*, *attribute\_name=None*)[#](#arthurai.core.models.ArthurModel.get_metrics "Permalink to this definition") +Retrieves metrics associated with the current model. Can add optional filters to search with function parameters. +:type default\_metrics: `bool` +:param default\_metrics: If set to True will return only metrics that are automatically created by default for your model +:type metric\_type: `Optional`[[`MetricType`](arthurai.core.alerts.MetricType.html#arthurai.core.alerts.MetricType "arthurai.core.alerts.MetricType")] +:param metric\_type: MetricType to filter metric query with +:type metric\_id: `Optional`[`str`] +:param metric\_id: Metric UUID to use in filtering metric search +:type metric\_name: `Optional`[`str`] +:param metric\_name: Metric name filter to use in metric search +:type attribute\_name: `Optional`[`str`] +:param attribute\_name: Attribute name filter to use in metric search +:rtype: `List`[[`Metric`](arthurai.core.alerts.Metric.html#arthurai.core.alerts.Metric "arthurai.core.alerts.Metric")] +:return: list of metrics returned from metric search +:permissions: metric\_query read + + + + + +get\_positive\_predicted\_class()[#](#arthurai.core.models.ArthurModel.get_positive_predicted_class "Permalink to this definition") +Checks if model is a binary classifier. Returns False if multiclass, otherwise returns the name of the positive +predicted attribute + + + + + +*property* ground\_truth\_type*: Optional[[arthurai.common.constants.Stage](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]*[#](#arthurai.core.models.ArthurModel.ground_truth_type "Permalink to this definition") +Returns GroundTruthClass if Arthur performed one-hot encoding +in the creation of this model’s current ground truth attribute. +Otherwise, returns GroundTruth. + + +The GroundTruthClass stage is an Arthur-generated stage of attributes, +which are made after one-hot encoding attributes of the GroundTruth stage. + + + +Return type +`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")] + + + + + + + +infer\_schema(*data*, *stage*)[#](#arthurai.core.models.ArthurModel.infer_schema "Permalink to this definition") +Auto-generate attributes based on input data + + +For an introduction to the model schema, see + + +Note that this method does *not* automatically set reference +data; this method only reads the passed-in data, and then infers attribute names, types, etc. and sets them up +within the ArthurModel. + + + +See also + + +To infer the model schema *and* set reference data in a single call, see [`ArthurModel.build()`](#arthurai.core.models.ArthurModel.build "arthurai.core.models.ArthurModel.build"). + + +Once you’ve inferred the model schema with this function, you may want to set reference data separately +with [`ArthurModel.set\_reference\_data()`](#arthurai.core.models.ArthurModel.set_reference_data "arthurai.core.models.ArthurModel.set_reference_data"). + + + +For PredictedValue and GroundTruth stages, use the correct add\_\_output\_attributes() method instead. + + + +Parameters +* **data** (`Union`[`DataFrame`, `Series`]) – the data to infer attribute metadata from +* **stage** ([`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")) – [`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") of the data + + + +Return type +`None` + + + +Returns +a DataFrame summarizing the inferred types + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +model\_is\_saved()[#](#arthurai.core.models.ArthurModel.model_is_saved "Permalink to this definition") +Returns True if and only if the model has been saved to the Arthur platform + + + +Return type +`bool` + + + + + + + +one\_hot\_encode(*value*)[#](#arthurai.core.models.ArthurModel.one_hot_encode "Permalink to this definition") +Creates a one hot encoding of a class label based on classes defined in a `ModelType.Multiclass` +model + + +This function does not modify your model’s attributes. + + + +``` +arthur\_model.one\_hot\_encode('attribute\_name') + +``` + + + +Parameters +**value** – the name of the ground truth attribute to one-hot-encode + + + +Returns +A dictionary with a one hot encoding of possible ground truth values. + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +query(*body*, *query\_type='base'*)[#](#arthurai.core.models.ArthurModel.query "Permalink to this definition") +Execute query against the model’s inferences. +For full description of possible functions, aggregations, and transformations, see + + + + +Parameters +* **body** (`Dict`[`str`, `Any`]) – dict +* **query\_type** – str Can be either ‘base’, ‘drift’, or ‘drift\_psi\_bucket\_table’ + + + + + +``` +body = { + "select":[ + {"property":"batch\_id"}, + { + "function":"count", + "alias":"inference\_count" + } + ], + "group\_by":[ + {"property":"batch\_id"} + ] + } + +``` + + + +``` +body = { + "select":[, + {"property":"batch\_id"}, + { + "function":"rate", + "alias":"positive\_rate", + "parameters":{ + "property":"predicted\_1", + "comparator":"gt", + "value":0.75 + } + } + ], + "group\_by":[ + {"property":"batch\_id"} + ] + } + +``` + + + +Returns +the query response + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data read + + + + + + + +remove\_attribute(*name=None*, *stage=None*, *attribute=None*)[#](#arthurai.core.models.ArthurModel.remove_attribute "Permalink to this definition") +Removes an already-made ArthurAttribute from the model. + + +Note that attributes may only be removed from unsaved models - for a saved model, attributes are immutable. + + + +Parameters +* **name** (`Optional`[`str`]) – Optional string, the name of the ArthurAttribute Object to remove from the model +* **stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – Optional Stage, the stage of the ArthurAttribute Object to remove from the model +* **attribute** (`Optional`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")]) – Optional ArthurAttribute Object to remove from the model + + + +Return type +`None` + + + +Returns +None + + + +Raises +* **MethodNotApplicableError** – failed due to incorrect usage on saved model +* **UserValueError** – failed due to user error inputting unrecognized attribute + + + + + + + +rename\_attribute(*old\_name*, *new\_name*, *stage*)[#](#arthurai.core.models.ArthurModel.rename_attribute "Permalink to this definition") +Renames an attribute by name and stage + + + +Parameters +* **old\_name** (`str`) – string name of the attribute to rename +* **new\_name** (`str`) – string new name of the attribute +* **stage** ([`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")) – Stage of attribute + + + +Return type +[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute") + + + +Returns +ArthurAttribute Object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +review(*stage=None*, *props=None*, *print\_df=False*)[#](#arthurai.core.models.ArthurModel.review "Permalink to this definition") +Prints a summary of the properties of all attributes in the model. + + + +Parameters +* **stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – restrict the output to a particular [`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage") (defaults to all stages) +* **props** (`Optional`[`List`[`str`]]) – a list of properties to display in the summary +valid properties are data\_type, categorical, is\_unique, +categories, cutoffs, range, monitor\_for\_bias, position +(defaults to data\_type, categorical, is\_unique) +* **print\_df** – boolean value whether to print df or return it, defaults to False + + + +Return type +`Optional`[`DataFrame`] + + + +Returns +a DataFrame summarizing the inferred types; or None if print\_df is True + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +save()[#](#arthurai.core.models.ArthurModel.save "Permalink to this definition") +Check and save this model + + +After this method is called successfully, your model is sent to the Arthur Platform +where all its data and metrics are saved. + + +Returns the model’s ID in the Arthur platform once the upload is successful. + + + +``` +model\_id = arthur\_model.save() +with open("fullguide\_model\_id.txt", "w") as f: + f.write(model\_id) # saving this model's id to a local file + +``` + + + +Return type +`str` + + + +Returns +The model id + + + +Raises +* **MethodNotApplicableError** – the model has already been saved +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +model write AND (usually) reference\_data write + + + + + + + +send\_batch\_ground\_truths(*directory\_path=None*, *data=None*)[#](#arthurai.core.models.ArthurModel.send_batch_ground_truths "Permalink to this definition") + +Deprecated since version 3.10.0: Please use [`ArthurModel.send\_bulk\_ground\_truths()`](#arthurai.core.models.ArthurModel.send_bulk_ground_truths "arthurai.core.models.ArthurModel.send_bulk_ground_truths") for both streaming and batch data. + + + + +Parameters +* **directory\_path** (`Optional`[`str`]) – file path to a directory of parquet files containing ground truth data +* **data** (`Union`[`DataFrame`, `Series`, `None`]) – a DataFrame or Series containing the reference data for the `Stage` + + + +Returns +Upload status response in the following format: + + + +``` +{ + "counts": { + "success": 1, + "failure": 0, + "total": 1 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +send\_batch\_inferences(*batch\_id*, *directory\_path=None*, *data=None*, *complete\_batch=True*)[#](#arthurai.core.models.ArthurModel.send_batch_inferences "Permalink to this definition") +Send many inferences at once + + + +Deprecated since version 3.10.0: Use [`ArthurModel.send\_inferences()`](#arthurai.core.models.ArthurModel.send_inferences "arthurai.core.models.ArthurModel.send_inferences") to send batch or streaming data synchronously (recommended fewer +than 100,000 rows), or [`ArthurModel.send\_bulk\_inferences()`](#arthurai.core.models.ArthurModel.send_bulk_inferences "arthurai.core.models.ArthurModel.send_bulk_inferences") to send many inferences or Parquet files. + + + + +Parameters +* **batch\_id** (`Optional`[`str`]) – string id for the batch to upload; if supplied, this will override any batch\_id column +specified in the provided dataset +* **data** (`Optional`[`DataFrame`]) – a DataFrame containing the reference data. +* **directory\_path** (`Optional`[`str`]) – file path to a directory of parquet files containing ground truth data +* **complete\_batch** (`bool`) – Defaults to true and will automatically close a batch once it is sent + + + +Returns +A tuple of the batch upload response and the close batch response. +The batch upload response is in the following format: + + + +``` +{ + "counts": { + "success": 0, + "failure": 0, + "total": 0 + }, + "failures": [] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +send\_bulk\_ground\_truths(*directory\_path=None*, *data=None*)[#](#arthurai.core.models.ArthurModel.send_bulk_ground_truths "Permalink to this definition") +Uploads a large batch of ground truth values to Arthur + + +Uploads a DataFrame or directory containing parquet files to the Arthur bulk inferences ingestion endpoint. +Recommended for uploads of >100,000 rows of data. + + + +Parameters +* **directory\_path** (`Optional`[`str`]) – file path to a directory of parquet files containing ground truth data. Required if +data is not provided, and cannot be populated if data is provided. +* **data** (`Union`[`DataFrame`, `Series`, `None`]) – a DataFrame or Series containing the ground truth data. Required if directory\_path is not +provided, and cannot be populated it directory\_path is not provided. + + + +Returns +Upload status response in the following format: + + + +``` +{ + "counts": { + "success": 0, + "failure": 0, + "total": 0 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + +send\_bulk\_inferences(*batch\_id=None*, *directory\_path=None*, *data=None*, *complete\_batch=True*, *ignore\_join\_errors=False*)[#](#arthurai.core.models.ArthurModel.send_bulk_inferences "Permalink to this definition") +Uploads a large batch of inferences to Arthur + + +Uploads a DataFrame or directory containing parquet files to the Arthur bulk inferences ingestion endpoint. +Recommended for uploads of >100,000 rows of data. + + +Validates and uploads parquet files containing columns for inference data, partner\_inference\_id, +inference\_timestamp, and optionally a batch\_id. Either directory\_path or data must be +specified. + + + +See also + + +To send ground truth for your inferences, see `ArthurModel.send\_bulk\_ground\_truth()` + + + +The columns for predicted attributes should follow the column format specified in +`add\_\_classifier\_output\_attributes()`. Additionally, `partner\_inference\_id`, +must be specified for all inferences unless `ignore\_join\_errors` is True. + + + +Parameters +* **batch\_id** (`Optional`[`str`]) – string id for the batch to upload; if supplied, this will override any batch\_id column +specified in the provided dataset +* **directory\_path** (`Optional`[`str`]) – file path to a directory of parquet files containing inference data. Required if +`data` is not provided, and cannot be populated if data is provided. +* **data** (`Optional`[`DataFrame`]) – a DataFrame or Series containing the inference data. Required if `directory\_path` is not +provided, and cannot be populated if `directory\_path` is not provided. +* **complete\_batch** (`bool`) – Defaults to true and will automatically close a batch once it is sent +* **ignore\_join\_errors** (`bool`) – if True, allow inference data without `partner\_inference\_id` or ground truth data + + + +Returns +A tuple of the batch upload response and the close batch response. +The batch upload response is in the following format: + + + +``` +{ + "counts": { + "success": 1, + "failure": 0, + "total": 1 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + +send\_inference(*inference\_timestamp*, *partner\_inference\_id=''*, *model\_pipeline\_input=None*, *non\_input\_data=None*, *predicted\_value=None*, *ground\_truth=None*)[#](#arthurai.core.models.ArthurModel.send_inference "Permalink to this definition") + +Deprecated since version 3.20.0: Please use [`ArthurModel.send\_inferences()`](#arthurai.core.models.ArthurModel.send_inferences "arthurai.core.models.ArthurModel.send_inferences") to send a single inference. + + + + +Parameters +* **inference\_timestamp** (`Union`[`str`, `datetime`]) – timestamp for inference to send; generated by external partner (not Arthur) +* **partner\_inference\_id** (`str`) – an external id (partner\_inference\_id) to assign to the inferences +* **model\_pipeline\_input** – a mapping of the name of pipeline input attributes to their value +* **non\_input\_data** – a mapping of the name of non-input data attributes to their value +* **predicted\_value** – a mapping of the name of predicted value attributes to their value +* **ground\_truth** – a mapping of the name of ground truth attributes to their value + + + +Returns +Upload status response in the following format: + + + +``` +{ + "counts": { + "success": 0, + "failure": 0, + "total": 0 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + +send\_inferences(*inferences*, *predictions=None*, *inference\_timestamps=None*, *ground\_truths=None*, *ground\_truth\_timestamps=None*, *tz=None*, *partner\_inference\_ids=None*, *batch\_id=None*, *fail\_silently=False*, *complete\_batch=True*)[#](#arthurai.core.models.ArthurModel.send_inferences "Permalink to this definition") +Send inferences to the Arthur API. The inferences parameter may contain all the inference data, or only the +input data if predictions and metadata are supplied separately. At a minimum, input data and predictions should +be passed in: partner\_inference\_id, inference\_timestamp, and (if ground truth data is supplied) +ground\_truth\_timestamp fields are required by the Arthur API, but these will be generated if not supplied. + + + +See also + + +To send large amounts of data or Parquet files, see [`ArthurModel.send\_bulk\_inferences()`](#arthurai.core.models.ArthurModel.send_bulk_inferences "arthurai.core.models.ArthurModel.send_bulk_inferences") + + + +**Examples:** + + +An input dataframe and predicted probabilities array, leaving the partner inference IDs and timestamps to be +auto-generated: + + + +``` +input\_df = pd.DataFrame({"input\_attr": [2]}) +pred\_array = my\_sklearn\_model.predict\_proba(input\_df) +arthur\_model.send\_inferences(input\_df, predictions=pred\_array, batch\_id='batch1') + +``` + + +All data in the inferences parameter in the format expected by the +[Arthur API POST Inferences Endpoint](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/inferences/paths/~1models~1%7Bmodel_id%7D~1inferences/post): + + + +``` +inference\_data = [ + { + "inference\_timestamp": "2021-06-16T16:52:11Z", + "partner\_inference\_id": "inf1", + "batch\_id": "batch1", + "inference\_data": { + "input\_attr": 2, + "predicted\_attr": 0.6 + }, + "ground\_truth\_timestamp": "2021-06-16T16:53:45Z", + "ground\_truth\_data": { + "ground\_truth\_attr": 1 + } + } +] +arthur\_model.send\_inferences(inference\_data) + +``` + + +A list of dicts without nested inference\_data or ground\_truth fields: + + + +``` +inference\_data = [ + { + "inference\_timestamp": "2021-06-16T16:52:11Z", + "partner\_inference\_id": "inf1", + "batch\_id": "batch1", + "input\_attr": 2, + "predicted\_attr": 0.6, + "ground\_truth\_timestamp": "2021-06-16T16:53:45Z", + "ground\_truth\_attr": 1 + } +] +arthur\_model.send\_inferences(inference\_data) + +``` + + + +Parameters +* **inferences** (`Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`]) – inference data to send, containing at least input values and optionally predictions, ground +truth, timestamps, partner inference ids, and batch IDs. +* **predictions** (`Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`, `Sequence`[`Any`], `None`]) – the model predictions, in a table-like format for one or more columns or a list-like format +if the model has only one predicted column. overwrites any predictions supplied in the inferences parameter +* **inference\_timestamps** (`Optional`[`Sequence`[`Union`[`datetime`, `str`]]]) – the inference timestamps, in a list-like format as ISO-8601 strings or datetime +objects. if no timestamps are supplied in inferences or this parameter, they will be generated from the +current time. overwrites any timestamps in the inferences parameter. +* **ground\_truths** (`Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`, `Sequence`[`Any`], `None`]) – the optional ground truth data (true labels), in a table-like format for one or more +columns or a list-like format if the model has only one ground truth column. overwrites any ground truth values +supplied in the inferences parameter +* **ground\_truth\_timestamps** (`Optional`[`Sequence`[`Union`[`datetime`, `str`]]]) – the ground truth timestamps, in a list-like format as ISO-8601 strings or +datetime objects. if no ground truth timestamps are supplied in inferences or this parameter but ground truth +data is supplied, they will be generated from the current time. overwrites any timestamps in the inferences +parameter. +* **tz** (`Optional`[`str`]) – datetime timezone object or timezone string +* **partner\_inference\_ids** (`Optional`[`Sequence`[`str`]]) – partner\_inference\_ids to be attached to these inferences, which can be used to +send ground truth data later or retrieve specific inferences, in a list-like format containing strings. if no +partner\_inference\_ids are supplied in inference or this parameter, they will be auto-generated. +* **batch\_id** (`Optional`[`str`]) – a single batch ID to use for all inferences supplied. overwrites any batch IDs in the +inferences parameter +* **fail\_silently** (`bool`) – if True, log failed inferences but do not raise an exception +* **complete\_batch** (`bool`) – if True, mark all batches in this dataset as completed + + + +Returns +Upload status response in the following format: + + + +``` +{ + "counts": { + "success": 1, + "failure": 0, + "total": 1 + }, + "results": [ + { + "partner\_inference\_id" "inf-id", + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + +set\_attribute\_as\_sensitive(*attribute\_name*, *attribute\_stage=None*)[#](#arthurai.core.models.ArthurModel.set_attribute_as_sensitive "Permalink to this definition") +Sets the passed-in attribute to be sensitive by setting attr.monitor\_for\_bias = True. + + +You will need to call self.save() or self.update() after this method; we do not +automatically call the API in this method. + + + +Parameters +* **attribute\_name** (`str`) – Name of attribute to set as sensitive. +* **attribute\_stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – Stage of attribute to set as sensitive. + + + +Return type +`None` + + + +Returns +None + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +set\_attribute\_labels(*attribute\_name*, *labels*, *attribute\_stage=None*)[#](#arthurai.core.models.ArthurModel.set_attribute_labels "Permalink to this definition") +Sets labels for individual categories of a specific attribute + + +This function should be used to set the labels corresponding to the +different possible values that an attribute can take. + + + +``` +# labels the value 0 for the attribute 'education\_level' +# to have the label 'elementary', etc. +arthur\_model.set\_attribute\_labels( + 'education\_level', + {0 : 'elementary', 1 : 'middle', 2 : 'high', 3 : 'university'} +) + +``` + + + +Parameters +* **attribute\_name** (`str`) – Attribute name to set the categories labels +* **attribute\_stage** (`Optional`[[`Stage`](arthurai.common.constants.Stage.html#arthurai.common.constants.Stage "arthurai.common.constants.Stage")]) – Optional stage of the attribute which is being updated +* **labels** (`Dict`[`Union`[`int`, `str`], `str`]) – Dictionary where the key is the categorical value and the value is the string categorical label + + + +Returns +None + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +set\_predict\_function\_input\_order(*attributes*)[#](#arthurai.core.models.ArthurModel.set_predict_function_input_order "Permalink to this definition") +Sets the expected order of attributes used by the prediction function. + + +This function should be used when enabling explainability: +in particular, if your model’s predict function requires attributes +in a specific order, but the attribute positions have not yet been inferred correctly. + + + +Parameters +**attributes** (`List`[`str`]) – a list of attribute names + + + +Return type +`None` + + + +Returns +None + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +set\_reference\_data(*directory\_path=None*, *data=None*)[#](#arthurai.core.models.ArthurModel.set_reference_data "Permalink to this definition") +Validates and sets the reference data for the given stage to the provided data. + + +For an introduction to reference data, see + + +To set reference data at the same time as inferring the model schema, see [`ArthurModel.build()`](#arthurai.core.models.ArthurModel.build "arthurai.core.models.ArthurModel.build") +To infer the model schema without setting reference data, see [`ArthurModel.infer\_schema()`](#arthurai.core.models.ArthurModel.infer_schema "arthurai.core.models.ArthurModel.infer_schema") + + + +``` +# reference dataframe of model inputs +reference\_set = ... + +# produce model predictions on reference set +# in this example, the predictions are classification probabilities +preds = model.predict\_proba(reference\_set) + +# assign the column corresponding to the positive class +# as the `pred` attribute in the reference data +reference\_set["pred"] = preds[:, 1] + +# set ground truth labels +reference\_set["gt"] = ... + +# configure the ArthurModel to use this dataframe as reference data +arthur\_model.set\_reference\_data(data=reference\_set) + +``` + + +Either directory\_path or data must be provided. Additionally, there must be +one column per ModelPipelineInput and NonInput attribute. + + +For Image models, the image file path should be included as the image atribute value, in either +the parquet files specified by directory\_path or the DataFrame provided. + + + +Parameters +* **directory\_path** (`Optional`[`str`]) – file path to a directory of parquet files to upload for batch data +* **data** (`Union`[`DataFrame`, `Series`, `None`]) – a DataFrame or Series containing the ground truth data + + + +Returns +Returns a tuple, the first variable is the response from sending the reference set and the second +is the response from closing the dataset. + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +reference\_data write + + + + + + + +swap\_predicted\_attribute\_positions(*persist\_if\_saved=True*)[#](#arthurai.core.models.ArthurModel.swap_predicted_attribute_positions "Permalink to this definition") +Swap the position of the model’s two predicted attributes + + +This function should be used when enabling explainability: +in particular, if your model’s predict function requires attributes +in a specific order, but the attribute positions have not yet been inferred correctly. + + + +Parameters +**persist\_if\_saved** – if the model has been saved, call update() to persist the change + + + +Returns + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.models.ArthurModel.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.models.ArthurModel.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + +update()[#](#arthurai.core.models.ArthurModel.update "Permalink to this definition") +Update the current model object in the Arthur platform + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +model write + + + + + + + +update\_alert(*status*, *alert\_id*)[#](#arthurai.core.models.ArthurModel.update_alert "Permalink to this definition") +Updates alert to have a particular status. + + +For an introduction to alerts, see + + +For a guide to configuring alerts, see + + + +Parameters +* **status** ([`AlertStatus`](arthurai.core.alerts.AlertStatus.html#arthurai.core.alerts.AlertStatus "arthurai.core.alerts.AlertStatus")) – one of “resolved” or “acknowledged” +* **alert\_id** (`str`) – alert id + + + +Return type +[`Alert`](arthurai.core.alerts.Alert.html#arthurai.core.alerts.Alert "arthurai.core.alerts.Alert") + + + +Returns +updated alert object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +alert write + + + + + + + +update\_alert\_rule(*alert\_rule*, *alert\_rule\_id=None*)[#](#arthurai.core.models.ArthurModel.update_alert_rule "Permalink to this definition") +Updates alert rule fields included in the alert\_rule object for the specified alert rule id. If the +alert rules id field is present in the alert\_rule parameter that is used otherwise alert\_rule\_id +must be supplied + + +For an introduction to alerts, see + + +For a guide to configuring alerts, see + + + +Parameters +* **alert\_rule** ([`AlertRule`](arthurai.core.alerts.AlertRule.html#arthurai.core.alerts.AlertRule "arthurai.core.alerts.AlertRule")) – Object which contains fields to update on the specified alert rule +* **alert\_rule\_id** (`Optional`[`str`]) – If the alert rule id is not specified in the alert\_rule\_to\_update object then this +must be provided to determine which alert rule to update. + + + +Returns +Updates alert rule object + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +alert\_rule write + + + + + + + +update\_enrichment(*enrichment*, *enabled=None*, *config=None*)[#](#arthurai.core.models.ArthurModel.update_enrichment "Permalink to this definition") +Update the configuration for a single enrichment + + +For an introduction to enrichments, see + + +For a guide to configuring enrichments, see + + + +Parameters +* **enrichment** ([`Enrichment`](arthurai.common.constants.Enrichment.html#arthurai.common.constants.Enrichment "arthurai.common.constants.Enrichment")) – the enrichment to update +* **enabled** (`Optional`[`bool`]) – whether the enrichment should be enabled or disabled +* **config** (`Optional`[`Dict`[`str`, `Any`]]) – the configuration for the enrichment, None by default + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config write + + + +Return type +`Dict`[`str`, `Any`] + + + + + + + +update\_enrichments(*enrichment\_configs*)[#](#arthurai.core.models.ArthurModel.update_enrichments "Permalink to this definition") +Update the configuration for 1 or more enrichments. + + +For an introduction to enrichments, see + + +For a guide to configuring enrichments, see + + + +Parameters +**enrichment\_configs** (`Dict`[`Union`[`str`, [`Enrichment`](arthurai.common.constants.Enrichment.html#arthurai.common.constants.Enrichment "arthurai.common.constants.Enrichment")], `Any`]) – + +Dict containing the configuration for each enrichment + + + +``` +{ + "anomaly\_detection": { + "enabled": false + }, + "explainability": { + "config": { + "streaming\_explainability\_enabled": false, + "explanation\_nsamples": 1000, + "explanation\_algo": "lime", + "inference\_consumer\_score\_percent": "1.0" + }, + "enabled": true + } + "hotspots": { + "enabled": false + } +} + +``` + + + +Return type +`Dict`[`str`, `Any`] + + + +Returns +the resulting enrichments configuration + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +enrichment\_config write + + + + + + + +update\_inference\_ground\_truths(*ground\_truths*, *partner\_inference\_ids=None*, *ground\_truth\_timestamps=None*, *tz=None*, *fail\_silently=False*)[#](#arthurai.core.models.ArthurModel.update_inference_ground_truths "Permalink to this definition") +Updates inferences with the supplied ground truth values + + +For an introduction to sending data to Arthur, +see + + +The `ground\_truth` parameter may contain all the required data, or only the data for the attributes from +Stage.GroundTruth if metadata is supplied separately. At a minimum, Stage.GroundTruth attribute data and +`partner\_inference\_id` should be passed in, either along with the attribute data in the `ground\_truths` +parameter, or in the `partner\_inference\_ids` parameter. +Additionally, a `ground\_truth\_timestamp` field is required by the Arthur API, but this will be generated if +not supplied. + + + +See also + + +To send large amounts of data or Parquet files, see [`ArthurModel.send\_bulk\_ground\_truths()`](#arthurai.core.models.ArthurModel.send_bulk_ground_truths "arthurai.core.models.ArthurModel.send_bulk_ground_truths") + + + +**Examples:** + + +A DataFrame containing all required values: + + + +``` +y\_test = [1, 0, 1] +existing\_inference\_ids = [f"batch\_1-inf\_{i}" for i in len(y\_test)] +ground\_truth\_df = pd.DataFrame({"ground\_truth\_positive\_labels": y\_test, + "ground\_truth\_negative\_labels": 1 - y\_test, + "partner\_inference\_id": existing\_inference\_ids}) +arthur\_model.update\_inference\_ground\_truths(ground\_truth\_df) + +``` + + +A single list of values, with partner\_inference\_ids supplied separately: + + + +``` +y\_test = [14.3, 19.6, 15.7] +existing\_inference\_ids = [f"batch\_1-inf\_{i}" for i in len(y\_test)] +arthur\_model.update\_inference\_ground\_truths(y\_test, partner\_inference\_ids=existing\_inference\_ids) + +``` + + +All data in the inferences parameter in the format expected by the +[Arthur API PATCH Inferences Endpoint](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/inferences/paths/~1models~1%7Bmodel_id%7D~1inferences/patch): + + + +``` +ground\_truth\_data = [ + { + "partner\_inference\_id": "inf1", + "ground\_truth\_timestamp": "2021-06-16T16:53:45Z", + "ground\_truth\_data": { + "ground\_truth\_attr": 1 + } + } +] +arthur\_model.update\_inference\_ground\_truths(ground\_truth\_data) + +``` + + +A list of dicts without nested ground\_truth fields: + + + +``` +inference\_data = [ + { + "partner\_inference\_id": "inf1", + "ground\_truth\_timestamp": "2021-06-16T16:53:45Z", + "ground\_truth\_attr": 1 + } +] +arthur\_model.send\_inferences(inference\_data) + +``` + + + +Parameters +* **ground\_truths** (`Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`, `Sequence`[`Any`]]) – ground truth data to send, containing at least values for the ground truth attributes, +and optionally `ground\_truth\_timestamp` and `partner\_inference\_id`. +* **partner\_inference\_ids** (`Optional`[`Sequence`[`str`]]) – partner\_inference\_ids for the existing inferences to be updated, in a list-like +format as strings. Required if not a field in `ground\_truths`. +* **ground\_truth\_timestamps** (`Optional`[`Sequence`[`Union`[`datetime`, `str`]]]) – the ground truth timestamps, in a list-like format as ISO-8601 strings or +datetime objects. if no ground truth timestamps are supplied in `inferences` or this parameter, +they will be generated from the current time. overwrites any timestamps in the `ground\_truths` parameter. +* **tz** (`Optional`[`str`]) – datetime timezone object or timezone string +* **fail\_silently** (`bool`) – if True, log failed inferences but do not raise an exception. + + + +Returns +Upload status response in the following format: + + + +``` +{ + "counts": { + "success": 1, + "failure": 0, + "total": 1 + }, + "results": [ + { + "message": "success", + "status": 200 + } + ] +} + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + +Permissions +raw\_data write + + + + + + + + + + + +[Next + +arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) +[Previous + +arthurai.core.models](arthurai.core.models.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.models.ExplainabilityParameters.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.models.ExplainabilityParameters.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..0eda9ccc8c622ea4342d5ac3b0eb12e7473c15f6 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.models.ExplainabilityParameters.md.txt @@ -0,0 +1,517 @@ + + + + + + +arthurai.core.models.ExplainabilityParameters - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](#) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.models.ExplainabilityParameters[#](#arthurai-core-models-explainabilityparameters "Permalink to this headline") +============================================================================================================================= + + + + +*class* arthurai.core.models.ExplainabilityParameters(*enabled*, *explanation\_algo=None*, *model\_server\_cpu=None*, *model\_server\_memory=None*, *explanation\_nsamples=None*)[#](#arthurai.core.models.ExplainabilityParameters "Permalink to this definition") +Bases: [`arthurai.core.base.ArthurBaseJsonDataclass`](arthurai.core.base.ArthurBaseJsonDataclass.html#arthurai.core.base.ArthurBaseJsonDataclass "arthurai.core.base.ArthurBaseJsonDataclass") + + +Methods + + + + + + + + +| [`clean\_nones`](#arthurai.core.models.ExplainabilityParameters.clean_nones "arthurai.core.models.ExplainabilityParameters.clean_nones") | Helper function to filter out None objects from a json or dictionary representation of an object | +| `from\_dict` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `from\_json` | +rtype +`TypeVar`(`A`, bound= `DataClassJsonMixin`) + + | +| `schema` | +rtype +`SchemaF`[`TypeVar`(`A`)] + + | +| [`to\_dict`](#arthurai.core.models.ExplainabilityParameters.to_dict "arthurai.core.models.ExplainabilityParameters.to_dict") | Creates a dictionary representation of this object | +| [`to\_json`](#arthurai.core.models.ExplainabilityParameters.to_json "arthurai.core.models.ExplainabilityParameters.to_json") | Creates a json representation of this object | + + + +Attributes + + + + + + + + +| `dataclass\_json\_config` | | +| `explanation\_algo` | | +| `explanation\_nsamples` | | +| `model\_server\_cpu` | | +| `model\_server\_memory` | | +| `enabled` | | + + + + + +*static* clean\_nones(*d*)[#](#arthurai.core.models.ExplainabilityParameters.clean_nones "Permalink to this definition") +Helper function to filter out None objects from a json or dictionary representation of an object + + + +Parameters +**d** – a Dictionary or Json representation of an ArthurBaseJsonDataclass object + + + +Returns +Dictionary of the object with all None components removed + + + + + + + +to\_dict(*skip\_none=True*)[#](#arthurai.core.models.ExplainabilityParameters.to_dict "Permalink to this definition") +Creates a dictionary representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`dict` + + + +Returns +Dictionary of object data + + + + + + + +to\_json(*skip\_none=True*)[#](#arthurai.core.models.ExplainabilityParameters.to_json "Permalink to this definition") +Creates a json representation of this object + + +This function can be applied to any extension of the ArthurBaseJsonDataClass + + + +Return type +`str` + + + +Returns +json of object data + + + + + + + + + + + +[Next + +arthurai.core.util](arthurai.core.util.html) +[Previous + +arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.models.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.models.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..c9208c45b0955bc7919c89f3af628933946cf9a9 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.models.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai.core.models - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](#)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.models[#](#module-arthurai.core.models "Permalink to this headline") +================================================================================== + + +Classes + + + + + + + + +| [`ArthurModel`](arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel "arthurai.core.models.ArthurModel")(partner\_model\_id, input\_type, ...) | Arthur Model class represents the metadata which represents a registered model in the application | +| [`ArthurModelGroup`](arthurai.core.models.ArthurModelGroup.html#arthurai.core.models.ArthurModelGroup "arthurai.core.models.ArthurModelGroup")([id, name, description, ...]) | (BETA) The ArthurModelGroup class is a collection of the metadata which represents a group of models within a Model Group on the Arthur platform. | +| [`ExplainabilityParameters`](arthurai.core.models.ExplainabilityParameters.html#arthurai.core.models.ExplainabilityParameters "arthurai.core.models.ExplainabilityParameters")(enabled[, ...]) | | + + + + + + + + +[Next + +arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) +[Previous + +arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.NumpyEncoder.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.NumpyEncoder.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..077bf4d7f2fd027a07cbc449f9c37b017a1df7ca --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.NumpyEncoder.md.txt @@ -0,0 +1,522 @@ + + + + + + +arthurai.core.util.NumpyEncoder - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](#) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.NumpyEncoder[#](#arthurai-core-util-numpyencoder "Permalink to this headline") +================================================================================================= + + + + +*class* arthurai.core.util.NumpyEncoder(*\**, *skipkeys=False*, *ensure\_ascii=True*, *check\_circular=True*, *allow\_nan=True*, *sort\_keys=False*, *indent=None*, *separators=None*, *default=None*)[#](#arthurai.core.util.NumpyEncoder "Permalink to this definition") +Bases: `json.encoder.JSONEncoder` + + +Special json encoder for numpy types + + +Methods + + + + + + + + +| [`convert\_value`](#arthurai.core.util.NumpyEncoder.convert_value "arthurai.core.util.NumpyEncoder.convert_value") | Converts the given object from a numpy data type to a python data type, if the object is already a python data type it is returned | +| [`default`](#arthurai.core.util.NumpyEncoder.default "arthurai.core.util.NumpyEncoder.default") | Implement this method in a subclass such that it returns a serializable object for `o`, or calls the base implementation (to raise a `TypeError`). | +| [`encode`](#arthurai.core.util.NumpyEncoder.encode "arthurai.core.util.NumpyEncoder.encode") | Return a JSON string representation of a Python data structure. | +| [`iterencode`](#arthurai.core.util.NumpyEncoder.iterencode "arthurai.core.util.NumpyEncoder.iterencode") | Encode the given object and yield each string representation as available. | + + + +Attributes + + + + + + + + +| `item\_separator` | | +| `key\_separator` | | + + + + + +*static* convert\_value(*obj*)[#](#arthurai.core.util.NumpyEncoder.convert_value "Permalink to this definition") +Converts the given object from a numpy data type to a python data type, if the object is already a +python data type it is returned + + + +Parameters +**obj** – object to convert + + + +Returns +python data type version of the object + + + + + + + +default(*o*)[#](#arthurai.core.util.NumpyEncoder.default "Permalink to this definition") +Implement this method in a subclass such that it returns +a serializable object for `o`, or calls the base implementation +(to raise a `TypeError`). + + +For example, to support arbitrary iterators, you could +implement default like this: + + + +``` +def default(self, o): + try: + iterable = iter(o) + except TypeError: + pass + else: + return list(iterable) + # Let the base class default method raise the TypeError + return JSONEncoder.default(self, o) + +``` + + + + + +encode(*o*)[#](#arthurai.core.util.NumpyEncoder.encode "Permalink to this definition") +Return a JSON string representation of a Python data structure. + + + +``` +>>> from json.encoder import JSONEncoder +>>> JSONEncoder().encode({"foo": ["bar", "baz"]}) +'{"foo": ["bar", "baz"]}' + +``` + + + + + +iterencode(*o*, *\_one\_shot=False*)[#](#arthurai.core.util.NumpyEncoder.iterencode "Permalink to this definition") +Encode the given object and yield each string +representation as available. + + +For example: + + + +``` +for chunk in JSONEncoder().iterencode(bigobject): + mysocket.write(chunk) + +``` + + + + + + + + + +[Next + +arthurai.core.viz](arthurai.core.viz.html) +[Previous + +arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.dataframe_like_to_list_of_dicts.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.dataframe_like_to_list_of_dicts.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..233c338a3ecc8ce4f26c26693e3d809f198537e7 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.dataframe_like_to_list_of_dicts.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](#) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts[#](#arthurai-core-util-dataframe-like-to-list-of-dicts "Permalink to this headline") +============================================================================================================================================ + + + + +arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts(*data*)[#](#arthurai.core.util.dataframe_like_to_list_of_dicts "Permalink to this definition") +Standardize data in a List of Dicts format (e.g. [{‘a’: 1, ‘b’: 2}, {‘a’: 3, ‘b’: 4}]). Input can be formatted as +a List of Dicts, Dict of Lists (e.g. {‘a’: [1, 3], ‘b’: [2, 4]}), or a Pandas DataFrame. May return the same +object as input if it already matches the correct format. +:type data: `Union`[`List`[`Dict`[`str`, `Any`]], `Dict`[`str`, `List`[`Any`]], `DataFrame`] +:param data: the input data to format +:return: the data restructured as a Dict of Lists +:raises UserTypeError: if the data is in an unexpected format + + + + + + + + +[Next + +arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) +[Previous + +arthurai.core.util](arthurai.core.util.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.intersection_is_non_empty.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.intersection_is_non_empty.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..23b7f02bc3bea2c00267d177ea9a0783e38b01ea --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.intersection_is_non_empty.md.txt @@ -0,0 +1,411 @@ + + + + + + +arthurai.core.util.intersection\_is\_non\_empty - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](#) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.intersection\_is\_non\_empty[#](#arthurai-core-util-intersection-is-non-empty "Permalink to this headline") +============================================================================================================================== + + + + +arthurai.core.util.intersection\_is\_non\_empty(*iter1*, *iter2*)[#](#arthurai.core.util.intersection_is_non_empty "Permalink to this definition") +Returns True if the two iterables share at least one element +:type iter1: `Iterable`[`Any`] +:param iter1: +:type iter2: `Iterable`[`Any`] +:param iter2: +:return: + + + + + + + + +[Next + +arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) +[Previous + +arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e4329b1c2b48aaa9a80141d9c7632a45edc029c2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.md.txt @@ -0,0 +1,443 @@ + + + + + + +arthurai.core.util - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](#)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util[#](#module-arthurai.core.util "Permalink to this headline") +============================================================================== + + +Functions + + + + + + + + +| [`dataframe\_like\_to\_list\_of\_dicts`](arthurai.core.util.dataframe_like_to_list_of_dicts.html#arthurai.core.util.dataframe_like_to_list_of_dicts "arthurai.core.util.dataframe_like_to_list_of_dicts")(data) | Standardize data in a List of Dicts format (e.g. | +| [`intersection\_is\_non\_empty`](arthurai.core.util.intersection_is_non_empty.html#arthurai.core.util.intersection_is_non_empty "arthurai.core.util.intersection_is_non_empty")(iter1, iter2) | Returns True if the two iterables share at least one element :type iter1: `Iterable`[`Any`] :param iter1: :type iter2: `Iterable`[`Any`] :param iter2: :return: | +| [`retrieve\_parquet\_files`](arthurai.core.util.retrieve_parquet_files.html#arthurai.core.util.retrieve_parquet_files "arthurai.core.util.retrieve_parquet_files")(directory\_path) | Checks whether a given directory and its subdirectories contain parquet files, if so this will return a list of the files | +| [`standardize\_pd\_obj`](arthurai.core.util.standardize_pd_obj.html#arthurai.core.util.standardize_pd_obj "arthurai.core.util.standardize_pd_obj")(data, dropna, replacedatetime) | Standardize pandas object for nans and datetimes. | +| [`update\_column\_in\_list\_of\_dicts`](arthurai.core.util.update_column_in_list_of_dicts.html#arthurai.core.util.update_column_in_list_of_dicts "arthurai.core.util.update_column_in_list_of_dicts")(data, ...) | Adds column\_values to target\_column in a list of dicts **in place**. | + + + +Classes + + + + + + + + +| [`NumpyEncoder`](arthurai.core.util.NumpyEncoder.html#arthurai.core.util.NumpyEncoder "arthurai.core.util.NumpyEncoder")(\*[, skipkeys, ensure\_ascii, ...]) | Special json encoder for numpy types | + + + + + + + + +[Next + +arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) +[Previous + +arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + On this page + + + + +* [arthurai.core.util](#) + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.retrieve_parquet_files.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.retrieve_parquet_files.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..8b47872eb4cd525c7d26ff6f215de88cf1a1c2ab --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.retrieve_parquet_files.md.txt @@ -0,0 +1,424 @@ + + + + + + +arthurai.core.util.retrieve\_parquet\_files - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](#) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.retrieve\_parquet\_files[#](#arthurai-core-util-retrieve-parquet-files "Permalink to this headline") +======================================================================================================================= + + + + +arthurai.core.util.retrieve\_parquet\_files(*directory\_path*)[#](#arthurai.core.util.retrieve_parquet_files "Permalink to this definition") +Checks whether a given directory and its subdirectories contain parquet files, +if so this will return a list of the files + + + +Parameters +**directory\_path** (`str`) – local path to check files types + + + +Return type +`List`[`Path`] + + + +Returns +List of paths for parquet files that are found + + + + + + + + + + +[Next + +arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) +[Previous + +arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.standardize_pd_obj.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.standardize_pd_obj.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..180ae81fe4170d5de13fd5d0d23da246fd052c55 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.standardize_pd_obj.md.txt @@ -0,0 +1,436 @@ + + + + + + +arthurai.core.util.standardize\_pd\_obj - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](#) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.standardize\_pd\_obj[#](#arthurai-core-util-standardize-pd-obj "Permalink to this headline") +=============================================================================================================== + + + + +arthurai.core.util.standardize\_pd\_obj(*data*, *dropna*, *replacedatetime*, *attributes=None*)[#](#arthurai.core.util.standardize_pd_obj "Permalink to this definition") +Standardize pandas object for nans and datetimes. + + +Standardization includes casting correct type for int columns that are float due to nans and +for converting datetime objects into isoformatted strings. + + + +Parameters +* **data** (`Union`[`DataFrame`, `Series`]) – the pandas data to standardize +* **dropna** (`bool`) – if True, drop nans from numeric date columns +* **replacedatetime** (`bool`) – if True, replace timestamps with isoformatted strings +* **attributes** (`Optional`[`Dict`[`str`, `Union`[`str`, [`ValueType`](arthurai.common.constants.ValueType.html#arthurai.common.constants.ValueType "arthurai.common.constants.ValueType")]]]) – if used for sending inferences, will handle column type conversions for columns with any nulls + + + +Return type +`Union`[`DataFrame`, `Series`] + + + +Returns +the standardized pandas data + + + +Raises +* **TypeError** – timestamp is not of type datetime.datetime +* **ValueError** – timestamp is not timezone aware and no location data is provided to remedy + + + + + + + + + + +[Next + +arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) +[Previous + +arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.util.update_column_in_list_of_dicts.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.util.update_column_in_list_of_dicts.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..f5a13f2d166c24da5dcc9aa5d60168107417ae81 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.util.update_column_in_list_of_dicts.md.txt @@ -0,0 +1,416 @@ + + + + + + +arthurai.core.util.update\_column\_in\_list\_of\_dicts - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](#) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.util.update\_column\_in\_list\_of\_dicts[#](#arthurai-core-util-update-column-in-list-of-dicts "Permalink to this headline") +========================================================================================================================================== + + + + +arthurai.core.util.update\_column\_in\_list\_of\_dicts(*data*, *target\_column*, *column\_values*)[#](#arthurai.core.util.update_column_in_list_of_dicts "Permalink to this definition") +Adds column\_values to target\_column in a list of dicts **in place**. If values are present for target\_column, they are +overwritten. +:type data: `List`[`Dict`[`str`, `Any`]] +:param data: the List of Dict data to modify +:type target\_column: `str` +:param target\_column: the name of the column to write values into +:type column\_values: `Sequence`[`Any`] +:param column\_values: the values to write +:rtype: `None` +:return: None (in place) +:raises UserValueError: if the lengths don’t match or aren’t retrievable + + + + + + + + +[Next + +arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) +[Previous + +arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..1f79a098f7ebccae417298a867a6d69afd8d03f0 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.md.txt @@ -0,0 +1,411 @@ + + + + + + +arthurai.core.viz - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](#)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz[#](#module-arthurai.core.viz "Permalink to this headline") +============================================================================ + + + + + + + + +| [`arthurai.core.viz.style`](arthurai.core.viz.style.html#module-arthurai.core.viz.style "arthurai.core.viz.style") | | +| [`arthurai.core.viz.utils`](arthurai.core.viz.utils.html#module-arthurai.core.viz.utils "arthurai.core.viz.utils") | | +| [`arthurai.core.viz.visualizer`](arthurai.core.viz.visualizer.html#module-arthurai.core.viz.visualizer "arthurai.core.viz.visualizer") | | + + + + + + + + +[Next + +arthurai.core.viz.style](arthurai.core.viz.style.html) +[Previous + +arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.style.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.style.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a9d8105501ea412bf157654a3b2ecc3bc5fa586f --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.style.md.txt @@ -0,0 +1,399 @@ + + + + + + +arthurai.core.viz.style - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](#) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.style[#](#module-arthurai.core.viz.style "Permalink to this headline") +======================================================================================== + + + + + + + +[Next + +arthurai.core.viz.utils](arthurai.core.viz.utils.html) +[Previous + +arthurai.core.viz](arthurai.core.viz.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.get_pred_and_gt_attrs.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.get_pred_and_gt_attrs.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..9feb1a334599972fbb4eb6069f609167152f2e53 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.get_pred_and_gt_attrs.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](#) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs[#](#arthurai-core-viz-utils-get-pred-and-gt-attrs "Permalink to this headline") +================================================================================================================================= + + + + +arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs(*arthur\_model*)[#](#arthurai.core.viz.utils.get_pred_and_gt_attrs "Permalink to this definition") +Returns the name of the predicted attribute and ground truth attribute for a model. + + + +Parameters +**arthur\_model** – an ArthurModel object + + + + + + + + + + +[Next + +arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) +[Previous + +arthurai.core.viz.utils](arthurai.core.viz.utils.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..0915b935251d6281a07bb05a997d4132489b591f --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.core.viz.utils - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](#)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.utils[#](#module-arthurai.core.viz.utils "Permalink to this headline") +======================================================================================== + + +Functions + + + + + + + + +| [`get\_pred\_and\_gt\_attrs`](arthurai.core.viz.utils.get_pred_and_gt_attrs.html#arthurai.core.viz.utils.get_pred_and_gt_attrs "arthurai.core.viz.utils.get_pred_and_gt_attrs")(arthur\_model) | Returns the name of the predicted attribute and ground truth attribute for a model. | +| [`savgol\_filter`](arthurai.core.viz.utils.savgol_filter.html#arthurai.core.viz.utils.savgol_filter "arthurai.core.viz.utils.savgol_filter")(signal) | Simple instantiation of Savitzky-Golay filter (cubic). | + + + + + + + + +[Next + +arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) +[Previous + +arthurai.core.viz.style](arthurai.core.viz.style.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.savgol_filter.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.savgol_filter.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..0b5fd5f3f37ce1a7b89a06e22b494a870c78ecab --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.utils.savgol_filter.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.core.viz.utils.savgol\_filter - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](#) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.utils.savgol\_filter[#](#arthurai-core-viz-utils-savgol-filter "Permalink to this headline") +============================================================================================================== + + + + +arthurai.core.viz.utils.savgol\_filter(*signal*)[#](#arthurai.core.viz.utils.savgol_filter "Permalink to this definition") +Simple instantiation of Savitzky-Golay filter (cubic). + + + +Parameters +**signal** – a numpy 1D array + + + + + + + + + + +[Next + +arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html) +[Previous + +arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.DataVisualizer.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.DataVisualizer.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..932ae60cdc863f401b8bd3e11313df7453112965 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.DataVisualizer.md.txt @@ -0,0 +1,478 @@ + + + + + + +arthurai.core.viz.visualizer.DataVisualizer - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](#) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.visualizer.DataVisualizer[#](#arthurai-core-viz-visualizer-datavisualizer "Permalink to this headline") +========================================================================================================================= + + + + +*class* arthurai.core.viz.visualizer.DataVisualizer(*arthur\_models*)[#](#arthurai.core.viz.visualizer.DataVisualizer "Permalink to this definition") +Bases: `object` + + +Methods + + + + + + + + +| [`drift\_series`](#arthurai.core.viz.visualizer.DataVisualizer.drift_series "arthurai.core.viz.visualizer.DataVisualizer.drift_series") | Generates a line series visualization of data drift metrics for selected attributes. | +| [`metric\_series`](#arthurai.core.viz.visualizer.DataVisualizer.metric_series "arthurai.core.viz.visualizer.DataVisualizer.metric_series") | Generates a line series visualization for selected metrics. | +| [`timeline`](#arthurai.core.viz.visualizer.DataVisualizer.timeline "arthurai.core.viz.visualizer.DataVisualizer.timeline") | Generates a visualization of the distribution of an attribute over time. | + + + + + +drift\_series(*attribute\_names*, *drift\_metric='PSI'*, *time\_resolution='day'*)[#](#arthurai.core.viz.visualizer.DataVisualizer.drift_series "Permalink to this definition") +Generates a line series visualization of data drift metrics for selected attributes. + + + +``` +# plot the KLDivergence drift of features X1, X2, and X3 by the hour +arthur\_model.viz.drift\_series(["X1", "X2", "X3"], drift\_metric="KLDivergence", time\_resolution="hour") + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +metric\_series(*metric\_names*, *time\_resolution='day'*)[#](#arthurai.core.viz.visualizer.DataVisualizer.metric_series "Permalink to this definition") +Generates a line series visualization for selected metrics. + + + +``` +# plot both the model's AUC metric and the model's FPR metric by the hour +arthur\_model.viz.metric\_series(["auc", "falsePositiveRate"], time\_resolution="hour") + +``` + + + +Raises +* **ArthurUserError** – failed due to user error +* **ArthurInternalError** – failed due to an internal error + + + + + + + +timeline(*attribute\_name*)[#](#arthurai.core.viz.visualizer.DataVisualizer.timeline "Permalink to this definition") +Generates a visualization of the distribution of an attribute over time. +For categorical attributes, a stacked area chart over time. +For continuous attributes, a joyplot showing probability densities over time. +:raises ArthurUserError: failed due to user error +:raises ArthurInternalError: failed due to an internal error + + + + + + + + + +[Next + +arthurai.explainability](arthurai.explainability.html) +[Previous + +arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.md.txt b/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d92886dcc96cf2e3d34568e1638bcb246250ec73 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.core.viz.visualizer.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.core.viz.visualizer - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](#)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.core.viz.visualizer[#](#module-arthurai.core.viz.visualizer "Permalink to this headline") +================================================================================================== + + +Classes + + + + + + + + +| [`DataVisualizer`](arthurai.core.viz.visualizer.DataVisualizer.html#arthurai.core.viz.visualizer.DataVisualizer "arthurai.core.viz.visualizer.DataVisualizer")(arthur\_models) | | + + + + + + + + +[Next + +arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) +[Previous + +arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.ArthurExplainer.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.ArthurExplainer.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d70a74f6c4c7052a8afc40fa1e1dc8be3a9019fb --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.ArthurExplainer.md.txt @@ -0,0 +1,874 @@ + + + + + + +arthurai.explainability.arthur\_explainer.ArthurExplainer - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](#) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.arthur\_explainer.ArthurExplainer[#](#arthurai-explainability-arthur-explainer-arthurexplainer "Permalink to this headline") +==================================================================================================================================================== + + + + +*class* arthurai.explainability.arthur\_explainer.ArthurExplainer(*model\_type*, *model\_input\_type*, *predicted\_attributes*, *predict\_func*, *data*, *label\_mapping*, *categorical\_features=None*, *enable\_shap=True*, *shap\_training\_samples=20*, *enable\_lime=True*, *text\_delimiter='\\\\W+'*, *load\_image\_func=None*, *predictions\_df=None*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer "Permalink to this definition") +Bases: `object` + + +Class for explaining inferences with a variety of libs + + +Methods + + + + + + + + +| `build\_image\_explainers` | +rtype +`None` + + | +| `build\_nlp\_explainers` | +rtype +`None` + + | +| `build\_tabular\_explainers` | +rtype +`None` + + | +| [`decode\_labels`](#arthurai.explainability.arthur_explainer.ArthurExplainer.decode_labels "arthurai.explainability.arthur_explainer.ArthurExplainer.decode_labels") | Decodes into strings | +| [`encode\_labels`](#arthurai.explainability.arthur_explainer.ArthurExplainer.encode_labels "arthurai.explainability.arthur_explainer.ArthurExplainer.encode_labels") | Encodes labels into integers | +| `explain\_image` | +rtype +`List`[`Dict`[`str`, `Any`]] + + | +| `explain\_image\_lime` | +rtype +`List`[`Dict`[`str`, `Any`]] + + | +| `explain\_nlp` | +rtype +`List`[`List`[`List`[`List`[`float`]]]] + + | +| `explain\_nlp\_lime` | +rtype +`List`[`List`[`List`[`List`[`float`]]]] + + | +| `explain\_tabular` | +rtype +`List`[`List`[`List`[`float`]]] + + | +| [`explain\_tabular\_lime`](#arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_lime "arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_lime") | Calculate lime values. | +| [`explain\_tabular\_shap`](#arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_shap "arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_shap") | Calculate SHAP values. | +| [`format\_lime\_image\_results`](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_image_results "arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_image_results") | Format LIME results for images | +| [`format\_lime\_results`](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results "arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results") | LIME's .as\_map() method returns scores looking like the following: | +| [`format\_lime\_results\_for\_one\_class`](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results_for_one_class "arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results_for_one_class") | This method unpacks the results for a single classes's explanation: | +| [`format\_lime\_text\_results`](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_text_results "arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_text_results") | Format LIME results for Text models | +| [`predict\_tabular`](#arthurai.explainability.arthur_explainer.ArthurExplainer.predict_tabular "arthurai.explainability.arthur_explainer.ArthurExplainer.predict_tabular") | Takes in customer provided data and returns the prediction values as numpy array (both regression and classification) | +| [`predict\_wrapper`](#arthurai.explainability.arthur_explainer.ArthurExplainer.predict_wrapper "arthurai.explainability.arthur_explainer.ArthurExplainer.predict_wrapper") | Wraps user supplied predict function. | +| [`shap\_expected\_values`](#arthurai.explainability.arthur_explainer.ArthurExplainer.shap_expected_values "arthurai.explainability.arthur_explainer.ArthurExplainer.shap_expected_values") | Returns expected values from the shap explainer for this model input type | + + + +Attributes + + + + + + + + +| `LIME` | | +| `SHAP` | | +| `num\_predicted\_attributes` | +rtype +`int` + + | + + + + + +decode\_labels(*feature\_vector*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.decode_labels "Permalink to this definition") +Decodes into strings + + + +Return type +`Iterable` + + + + + + + +encode\_labels(*feature\_vector*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.encode_labels "Permalink to this definition") +Encodes labels into integers + + + +Return type +`Iterable` + + + + + + + +explain\_tabular\_lime(*raw\_feature\_vectors*, *\*\*kwargs*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_lime "Permalink to this definition") +Calculate lime values. For one or more inferences. + + + +Parameters +* **raw\_feature\_vectors** (`List`) – An iterable of one or more feature vectors to explain. +* **kwargs** – Additional args to pass to LIME. + + + +Return type +`List`[`List`[`List`[`float`]]] + + + +Returns +A List of explanations for each feature vector. A single explanation is +a list of lists that contain the explanation for each model output by input feature. +In this example, the model has 4 features and 3 output classes: + + + +``` +[ + [ + [-0.011, 0.009, -0.128, -0.161], + [-0.009, 0.003, -0.091, -0.065], + [0.02, -0.013, 0.220, 0.226] + ] +] + +``` + + + + + + + +explain\_tabular\_shap(*raw\_feature\_vectors*, *\*\*kwargs*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.explain_tabular_shap "Permalink to this definition") +Calculate SHAP values. For one or more inferences. + + + +Parameters +* **raw\_feature\_vectors** (`List`) – An iterable of one or more feature vectors to explain. +* **kwargs** – Additional args to pass to SHAP. + + + +Return type +`List`[`List`[`List`[`float`]]] + + + +Returns +A List of explanations for each feature vector. A single explanation is a list of lists that contain +the explanation for each model output by input feature. In this example, the model has 4 features and +3 output classes. + + + +``` +[ + [-0.011, 0.009, -0.128, -0.161], + [-0.009, 0.003, -0.091, -0.065], + [0.02, -0.013, 0.220, 0.226] +] + +``` + + + + + + + +*static* format\_lime\_image\_results(*results*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_image_results "Permalink to this definition") +Format LIME results for images + + + +Return type +`List`[`Dict`[`str`, `Any`]] + + + +Returns +formatted output in the following format: + + + +``` +{ + "lime\_segment\_mask": [ + [1, 1, 1, 3, 3, 1, 0], + [1, 1, 1, 3, 3, 1, 0], + [1, 1, 1, 3, 3, 1, 0], + [2, 2, 2, 3, 3, 1, 0] + ], + "lime\_region\_mapping": { + "0": [[0, 0.23], [1, 0.3], [2, 0.001], [3, -0.5]] + } +} + +``` + + + + + + + +format\_lime\_results(*results*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results "Permalink to this definition") +LIME’s .as\_map() method returns scores looking like the following: + + + +> +> +> ``` +> { +> 0:[ +> (3, -0.1614709564346036), +> (2, -0.12871035938256958), +> (0, -0.011225126011010974), +> (1, 0.009948039509525414) +> ], +> 1:[ +> (2, -0.0914379318506283), +> (3, -0.06513690080871648), +> (0, -0.009164069675758498), +> (1, 0.003622751782692439) +> ], +> 2:[ +> (3, 0.2266078572433201), +> (2, 0.22014829123319787), +> (0, 0.02038919568676947), +> (1, -0.013570791292217853) +> ] +> } +> +> ``` +> +> +> + + +Where the keys are the class labels, and the values are lists of feature index, score tuples for that class. + + +This method unpacks the result to a list of lists for EACH explanation: + + + +> +> +> ``` +> [ +> [-0.011, 0.009, -0.128, -0.161], +> [-0.009, 0.003, -0.091, -0.065], +> [0.02, -0.013, 0.220, 0.226] +> ] +> +> ``` +> +> +> + + +For regression, this will return a list of lists for one class per inference: + + + +> +> +> ``` +> [ +> [-0.011, 0.009, -0.128, -0.161] +> ] +> +> ``` +> +> +> + + + +Return type +`List`[`List`[`List`[`float`]]] + + + + + + + +*static* format\_lime\_results\_for\_one\_class(*feature\_index\_score\_pairs*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_results_for_one_class "Permalink to this definition") +This method unpacks the results for a single classes’s explanation: + + + +> +> +> ``` +> [ +> (3, -0.1614709564346036), +> (2, -0.12871035938256958), +> (0, -0.011225126011010974), +> (1, 0.009948039509525414) +> ] +> +> ``` +> +> +> + + + +Return type +`List`[`float`] + + + +Returns +unpacked lime results for a single class + + + +``` +[-0.011, 0.009, -0.128, -0.161] + +``` + + + + + + + +format\_lime\_text\_results(*results*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.format_lime_text_results "Permalink to this definition") +Format LIME results for Text models + + +LIME’s .as\_map() method returns scores looking like the following: + + + +``` +{0: [('I', -0.1614709564346036), ('a', -0.12871035938256958), ('am', -0.011225126011010974), ('developer', 0.009948039509525414)], + 1: [('am', -0.0914379318506283), ('a', -0.06513690080871648), ('I', -0.009164069675758498), ('developer', 0.003622751782692439)], + 2: [('developer', 0.2266078572433201), ('am', 0.22014829123319787), ('a', 0.02038919568676947), ('I', -0.013570791292217853)]} + +``` + + +Where the keys are the class labels, and the values are lists of word, score tuples for that class. + + +This method unpacks the result to a list of lists for EACH explanation: + + + +``` +[ + [['I', -0.011], ['am', 0.009], ['a', -0.128], ['developer', -0.161]], + [['I', -0.02], ['am', 0.007], ['a', -0.8], ['developer', 0.11]], + [['I', -0.03], ['am', 0.89], ['a', -0.28], ['developer', -0.16]] +] + +``` + + +For regression, this will return a list of lists for one class per inference: + + + +``` +[ + [['I', -0.011], ['am', 0.009], ['a', -0.128], ['developer', -0.161]] +] + +``` + + + +Return type +`List`[`List`[`List`[`List`[`float`]]]] + + + +Returns +formatted results in the following format + + + +``` +[ + [['I', -0.011], ['am', 0.009], ['a', -0.128], ['developer', -0.161]], + [['I', -0.02], ['am', 0.007], ['a', -0.8], ['developer', 0.11]], + [['I', -0.03], ['am', 0.89], ['a', -0.28], ['developer', -0.16]] +] + +``` + + + + + + + +predict\_tabular(*input\_feature\_vectors*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.predict_tabular "Permalink to this definition") +Takes in customer provided data and returns the prediction values as numpy array (both regression and classification) + + + +Return type +`ndarray` + + + + + + + +predict\_wrapper(*encoded\_feature\_vectors*)[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.predict_wrapper "Permalink to this definition") +Wraps user supplied predict function. Handles decoding back into original format. +For binary classifiers, checks the output size and reshapes to two dimensions if necessary + + + +Return type +`ndarray` + + + + + + + +shap\_expected\_values()[#](#arthurai.explainability.arthur_explainer.ArthurExplainer.shap_expected_values "Permalink to this definition") +Returns expected values from the shap explainer for this model input type + + + +Return type +`List`[`float`] + + + + + + + + + + + +[Next + +arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) +[Previous + +arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..f4f3dac98560b6e3f16c186007e25cc786f17044 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.arthur_explainer.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.explainability.arthur\_explainer - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](#)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.arthur\_explainer[#](#module-arthurai.explainability.arthur_explainer "Permalink to this headline") +=========================================================================================================================== + + +Classes + + + + + + + + +| [`ArthurExplainer`](arthurai.explainability.arthur_explainer.ArthurExplainer.html#arthurai.explainability.arthur_explainer.ArthurExplainer "arthurai.explainability.arthur_explainer.ArthurExplainer")(model\_type, ...[, ...]) | Class for explaining inferences with a variety of libs | +| [`EmptyLimeExplanation`](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html#arthurai.explainability.arthur_explainer.EmptyLimeExplanation "arthurai.explainability.arthur_explainer.EmptyLimeExplanation")(class\_int\_labels, ...) | Class for representing an all-NaN LIME Explanation. | + + + + + + + + +[Next + +arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) +[Previous + +arthurai.explainability](arthurai.explainability.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.ExplanationPackager.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.ExplanationPackager.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..925e6f393a1ac6b4a07ab7fafdbac71ea261b3ea --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.ExplanationPackager.md.txt @@ -0,0 +1,627 @@ + + + + + + +arthurai.explainability.explanation\_packager.ExplanationPackager - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](#) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.explanation\_packager.ExplanationPackager[#](#arthurai-explainability-explanation-packager-explanationpackager "Permalink to this headline") +==================================================================================================================================================================== + + + + +*class* arthurai.explainability.explanation\_packager.ExplanationPackager(*model*, *\*\*kwargs*)[#](#arthurai.explainability.explanation_packager.ExplanationPackager "Permalink to this definition") +Bases: `object` + + +Manages the project source code and explainer for this model. +Intended only for internal use. Used to create explainer object, package files and format config for the +update enrichments API endpoint. + + +See model.update\_enrichments() for more details on usage + + +Methods + + + + + + + + +| [`build\_categorical\_lookup\_table`](#arthurai.explainability.explanation_packager.ExplanationPackager.build_categorical_lookup_table "arthurai.explainability.explanation_packager.ExplanationPackager.build_categorical_lookup_table") | Builds the lookup table that ArthurExplainer needs for encoding strings | +| [`contains\_file\_fields`](#arthurai.explainability.explanation_packager.ExplanationPackager.contains_file_fields "arthurai.explainability.explanation_packager.ExplanationPackager.contains_file_fields") | Returns (onePresent, allPresent) onePresent is true if at least one file field was supplied AllPresent is true if all file fields are supplied | +| [`copy\_files`](#arthurai.explainability.explanation_packager.ExplanationPackager.copy_files "arthurai.explainability.explanation_packager.ExplanationPackager.copy_files") | Copy the files that are required for testing the docker image. | +| [`create`](#arthurai.explainability.explanation_packager.ExplanationPackager.create "arthurai.explainability.explanation_packager.ExplanationPackager.create") | Create an explainer for this model. | +| [`create\_test\_script`](#arthurai.explainability.explanation_packager.ExplanationPackager.create_test_script "arthurai.explainability.explanation_packager.ExplanationPackager.create_test_script") | Create a test script. | +| [`get\_request\_config`](#arthurai.explainability.explanation_packager.ExplanationPackager.get_request_config "arthurai.explainability.explanation_packager.ExplanationPackager.get_request_config") | Generates config dict for explainer. | +| [`get\_request\_files`](#arthurai.explainability.explanation_packager.ExplanationPackager.get_request_files "arthurai.explainability.explanation_packager.ExplanationPackager.get_request_files") | Returns files needed for request, for use with model.update\_enrichments | +| [`make\_zip`](#arthurai.explainability.explanation_packager.ExplanationPackager.make_zip "arthurai.explainability.explanation_packager.ExplanationPackager.make_zip") | Create the zip file for the project directory. | +| [`test`](#arthurai.explainability.explanation_packager.ExplanationPackager.test "arthurai.explainability.explanation_packager.ExplanationPackager.test") | Download the docker container, install the files, and make sure the predict function can be run. | +| [`validate\_requirements\_add\_sklearn`](#arthurai.explainability.explanation_packager.ExplanationPackager.validate_requirements_add_sklearn "arthurai.explainability.explanation_packager.ExplanationPackager.validate_requirements_add_sklearn") | Checks the user requirements file to make sure versions are correct. | + + + +Attributes + + + + + + + + +| `FILE\_FIELDS` | | + + + + + +build\_categorical\_lookup\_table()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.build_categorical_lookup_table "Permalink to this definition") +Builds the lookup table that ArthurExplainer needs for encoding strings + + + +Return type +`List`[`Optional`[`Dict`[`str`, `int`]]] + + + + + + + +contains\_file\_fields()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.contains_file_fields "Permalink to this definition") +Returns (onePresent, allPresent) +onePresent is true if at least one file field was supplied +AllPresent is true if all file fields are supplied + + + +Return type +`Tuple`[`bool`, `bool`] + + + + + + + +copy\_files(*example*)[#](#arthurai.explainability.explanation_packager.ExplanationPackager.copy_files "Permalink to this definition") +Copy the files that are required for testing the docker image. + + + +Param +example: the example to use in the test script + + + +Return type +`None` + + + + + + + +create()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.create "Permalink to this definition") +Create an explainer for this model. + + + +Param +df: the training data for the explainer + + + +Param +shap\_nrows: number of rows to sample the dataframe passed in + + + +Return type +`None` + + + + + + + +create\_test\_script(*example*)[#](#arthurai.explainability.explanation_packager.ExplanationPackager.create_test_script "Permalink to this definition") +Create a test script. + + + +Param +example:the example to use in the test script + + + +Return type +`str` + + + +Returns +the script contents + + + + + + + +get\_request\_config()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.get_request_config "Permalink to this definition") +Generates config dict for explainer. For use with model.update\_enrichments + + + +Return type +`Dict`[`str`, `str`] + + + + + + + +get\_request\_files()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.get_request_files "Permalink to this definition") +Returns files needed for request, for use with model.update\_enrichments + + + +Return type +`List`[`Any`] + + + + + + + +make\_zip()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.make_zip "Permalink to this definition") +Create the zip file for the project directory. + + + +Return type +`None` + + + + + + + +test()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.test "Permalink to this definition") +Download the docker container, install the files, and make sure the predict function can be run. + + + +Return type +`None` + + + + + + + +validate\_requirements\_add\_sklearn()[#](#arthurai.explainability.explanation_packager.ExplanationPackager.validate_requirements_add_sklearn "Permalink to this definition") +Checks the user requirements file to make sure versions are correct. + + +Also handles making sure scikit-learn version is pinned in user requirements +file, if it is installed in local environment and not specified. + + +scikit-learn is a dependency of shap, and arthurai doesn’t require scikit-learn explicitly. +This can lead to version A being installed and used locally when pickling explainer, then version B +getting installed on model server as part of shap install. This can lead to pickle errors, +since the pickled version of shap (client side) used a different version of sklearn than what is on model +server. + + + +Return type +`List`[`str`] + + + + + + + + + + + +[Next + +arthurai.explainability.validation](arthurai.explainability.validation.html) +[Previous + +arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..108de7420026f6ea6c7e99dec745d18dc2c45b7d --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.explanation_packager.md.txt @@ -0,0 +1,412 @@ + + + + + + +arthurai.explainability.explanation\_packager - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](#)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.explanation\_packager[#](#module-arthurai.explainability.explanation_packager "Permalink to this headline") +=================================================================================================================================== + + +Classes + + + + + + + + +| [`ExplanationPackager`](arthurai.explainability.explanation_packager.ExplanationPackager.html#arthurai.explainability.explanation_packager.ExplanationPackager "arthurai.explainability.explanation_packager.ExplanationPackager")(model, \*\*kwargs) | Manages the project source code and explainer for this model. | + + + + + + + + +[Next + +arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) +[Previous + +arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..14b334b6afbbec79b8e9998f9a4d5e684c9c2635 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai.explainability - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](#)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability[#](#module-arthurai.explainability "Permalink to this headline") +======================================================================================== + + +Explainability functionality + + + + + + + + +| [`arthurai.explainability.arthur\_explainer`](arthurai.explainability.arthur_explainer.html#module-arthurai.explainability.arthur_explainer "arthurai.explainability.arthur_explainer") | | +| [`arthurai.explainability.explanation\_packager`](arthurai.explainability.explanation_packager.html#module-arthurai.explainability.explanation_packager "arthurai.explainability.explanation_packager") | | +| [`arthurai.explainability.validation`](arthurai.explainability.validation.html#module-arthurai.explainability.validation "arthurai.explainability.validation") | | + + + + + + + + +[Next + +arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html) +[Previous + +arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..aeff4a06f88035c58d0235a1560605b26fc313d2 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.md.txt @@ -0,0 +1,413 @@ + + + + + + +arthurai.explainability.validation - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](#)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.validation[#](#module-arthurai.explainability.validation "Permalink to this headline") +============================================================================================================== + + +Functions + + + + + + + + +| [`validate\_predicted\_attribute\_order\_matches\_dataframe`](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html#arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe "arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe")(...) | Helper function to check that the order of the predicted attributes matches the output from the user predict() function. | +| [`validate\_predicted\_attribute\_order\_matches\_remote`](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html#arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote "arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote")(model) | Checks that the position field of each predicted attribute matches the value when the model is fetched by ID from the API | + + + + + + + + +[Next + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) +[Previous + +arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..01c314048ef4be1513367f768ae3fa33baf84045 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.md.txt @@ -0,0 +1,432 @@ + + + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](#) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe[#](#arthurai-explainability-validation-validate-predicted-attribute-order-matches-dataframe "Permalink to this headline") +====================================================================================================================================================================================================================== + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe(*actual\_preds*, *sample\_data*, *predicted\_attributes*)[#](#arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe "Permalink to this definition") +Helper function to check that the order of the predicted attributes matches the output from the user predict() +function. + + +A common failure case is a user registering a binary classifier with a single positive predicted +attribute, but returning the value of predict\_proba() from their classifier. The result is that the implicit +negative column is registered as the second column (, ) but SkLearn and most other libraries +output with the negative prediction in the first column (, ). + + + +Parameters +* **actual\_preds** (`ndarray`) – predictions pulled from the user’s predict() function +* **sample\_data** (`DataFrame`) – a DataFrame containing user-provided predictions +* **predicted\_attributes** (`List`[[`ArthurAttribute`](arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute "arthurai.core.attributes.ArthurAttribute")]) – the model’s predicted attributes + + + +Returns +None + + + +Raises +**UserValueError** – if the prediction order doesn’t match or it cannot be determined + + + + + + + + + + +[Next + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) +[Previous + +arthurai.explainability.validation](arthurai.explainability.validation.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.md.txt b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..80152df8b2ff515d9af85586fa1ba98b0c9119b7 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.md.txt @@ -0,0 +1,429 @@ + + + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](#) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote[#](#arthurai-explainability-validation-validate-predicted-attribute-order-matches-remote "Permalink to this headline") +================================================================================================================================================================================================================ + + + + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote(*model*)[#](#arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote "Permalink to this definition") +Checks that the position field of each predicted attribute matches the value when the model is fetched by ID from +the API + + + +Parameters +**model** – model to validate + + + +Return type +`None` + + + +Returns +None + + + +Raises +**UserValueError** – if the positions don’t match + + + + + + + + + + +[Next + +arthurai.util](arthurai.util.html) +[Previous + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.md.txt b/files/arthur-docs-markdown/sdk/arthurai.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..86797aef32b411ce06f2b1f4df2cbd487465b368 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.md.txt @@ -0,0 +1,414 @@ + + + + + + +arthurai - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](#)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai[#](#module-arthurai "Permalink to this headline") +========================================================== + + + + + + + + +| [`arthurai.client`](arthurai.client.html#module-arthurai.client "arthurai.client") | Arthur HTTP client and general (non-model) functions | +| [`arthurai.common`](arthurai.common.html#module-arthurai.common "arthurai.common") | Constants, exceptions, and logging for use in other packages | +| [`arthurai.core`](arthurai.core.html#module-arthurai.core "arthurai.core") | Primary ArthurAI functionality | +| [`arthurai.explainability`](arthurai.explainability.html#module-arthurai.explainability "arthurai.explainability") | Explainability functionality | +| [`arthurai.util`](arthurai.util.html#module-arthurai.util "arthurai.util") | | +| [`arthurai.version`](arthurai.version.html#module-arthurai.version "arthurai.version") | | + + + + + + + + +[Next + +arthurai.client](arthurai.client.html) +[Previous + +Permissions by Function](../permissions.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamp.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamp.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..61e3aa1bfd3277178867c6dcc617492d27081840 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamp.md.txt @@ -0,0 +1,437 @@ + + + + + + +arthurai.util.format\_timestamp - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](#) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util.format\_timestamp[#](#arthurai-util-format-timestamp "Permalink to this headline") +================================================================================================ + + + + +arthurai.util.format\_timestamp(*timestamp*, *tz=None*)[#](#arthurai.util.format_timestamp "Permalink to this definition") +Check if timestamp is time aware and convert to ISO8601 conventioned string. + + +This helper function converts datetime objects into timezone aware ISO8601 strings, which is necessary when sending +JSON to Arthur’s backend. If timestamp argument is timezone aware, no location needs to be provided; otherwise, +a string pytz location like “US/Eastern” needs to be provided to establish timezone. String timestamp are +supported for backwards compatability and for simplicity are assumed to already be in UTC format, but string support +will be deprecated. + + + +Parameters +* **timestamp** (`Union`[`datetime`, `str`]) – timestamp to format +* **tz** (`Union`[`timezone`, `str`, `None`]) – datetime timezone object or timezone string + + + +Return type +`str` + + + +Returns +ISO8601 formatted timestamp + + + +Raises +* **TypeError** – timestamp is not of type datetime.datetime +* **ValueError** – timestamp is not timezone aware and no location data is provided to remedy + + + + + + + + + + +[Next + +arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) +[Previous + +arthurai.util](arthurai.util.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamps.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamps.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ec05b7a33c2b8981ee7cb81f74b9373c34ecbc16 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.format_timestamps.md.txt @@ -0,0 +1,431 @@ + + + + + + +arthurai.util.format\_timestamps - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](#) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util.format\_timestamps[#](#arthurai-util-format-timestamps "Permalink to this headline") +================================================================================================== + + + + +arthurai.util.format\_timestamps(*inferences*, *tz=None*, *timestamp\_attributes=None*)[#](#arthurai.util.format_timestamps "Permalink to this definition") +Checks list of json inferences to ensure their timestamps have been converted to ISO8601 conventions. + + + +Parameters +* **inferences** (`List`[`Dict`[`str`, `Any`]]) – Input to send\_inferences() function. +* **tz** (`Union`[`timezone`, `str`, `None`]) – datetime timezone object or timezone string +* **timestamp\_attributes** (`Optional`[`List`[`str`]]) – List of attributes of the model of timestamp type + + + +Return type +`List`[`Dict`[`str`, `Any`]] + + + +Returns +updated list of json inferences with ISO8601 formatted timestamps + + + +Raises +* **TypeError** – timestamp is not of type datetime.datetime +* **ValueError** – timestamp is not timezone aware and no location data is provided to remedy + + + + + + + + + + +[Next + +arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) +[Previous + +arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.generate_timestamps.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.generate_timestamps.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..fbbfa7f4d97da030098af2fb9674787b79af685c --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.generate_timestamps.md.txt @@ -0,0 +1,438 @@ + + + + + + +arthurai.util.generate\_timestamps - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](#) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util.generate\_timestamps[#](#arthurai-util-generate-timestamps "Permalink to this headline") +====================================================================================================== + + + + +arthurai.util.generate\_timestamps(*total*, *duration='7d'*, *end='now'*, *freq='D'*, *noisiness=0.3*)[#](#arthurai.util.generate_timestamps "Permalink to this definition") +Generates timestamps over a period of time, defaulting to daily timestamps over the last week. Creates uniques +unique timestamp values evenly spaced between start and end inclusively. Repeats values if +total ≠ uniques. This is useful for generating timestamps for test inferences outside of a production setting. + + + +Parameters +* **total** (`int`) – the total number of timestamps to generate +* **end** (`Union`[`str`, `datetime`]) – the final timestamp value +* **duration** (`Union`[`str`, `timedelta`]) – the difference between the first and last timestamp values. day or hour strings (e.g. “7d”, “4h”) +and timedelta objects are supported +* **freq** (`Union`[`str`, `DateOffset`]) – the frequency with which to generate unique values. See +[Pandas Offset Aliases](https://pandas.pydata.org/docs/user_guide/timeseries.html#offset-aliases) for values +* **noisiness** (`float`) – how much to noise to add to the number of timestamps repeated at each interval. specifically, the +coefficient of variation (standard deviation / mean) to use when selecting the number of times to repeat each +timestamp + + + +Raises +**UserValueError** – if an input is invalid or values contain future timestamps and allow\_future is False + + + +Return type +`List`[`datetime`] + + + +Returns +a list of generated timestamps + + + + + + + + + + +[Next + +arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) +[Previous + +arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..78485867e2226397869a811fbc9e513816687b57 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.md.txt @@ -0,0 +1,421 @@ + + + + + + +arthurai.util - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](#)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util[#](#module-arthurai.util "Permalink to this headline") +==================================================================== + + +Functions + + + + + + + + +| [`format\_timestamp`](arthurai.util.format_timestamp.html#arthurai.util.format_timestamp "arthurai.util.format_timestamp")(timestamp[, tz]) | Check if timestamp is time aware and convert to ISO8601 conventioned string. | +| [`format\_timestamps`](arthurai.util.format_timestamps.html#arthurai.util.format_timestamps "arthurai.util.format_timestamps")(inferences[, tz, ...]) | Checks list of json inferences to ensure their timestamps have been converted to ISO8601 conventions. | +| [`generate\_timestamps`](arthurai.util.generate_timestamps.html#arthurai.util.generate_timestamps "arthurai.util.generate_timestamps")(total[, duration, end, ...]) | Generates timestamps over a period of time, defaulting to daily timestamps over the last week. | +| [`is\_valid\_datetime\_string`](arthurai.util.is_valid_datetime_string.html#arthurai.util.is_valid_datetime_string "arthurai.util.is_valid_datetime_string")(dt\_obj) | " | +| [`normal\_random\_ints\_fixed\_sum`](arthurai.util.normal_random_ints_fixed_sum.html#arthurai.util.normal_random_ints_fixed_sum "arthurai.util.normal_random_ints_fixed_sum")(num\_values, ...) | Return num\_values roughly normally-distributed integers summing to total\_sum. | +| [`value\_type\_to\_python\_type`](arthurai.util.value_type_to_python_type.html#arthurai.util.value_type_to_python_type "arthurai.util.value_type_to_python_type")(value\_type) | +rtype +`Type` + + | + + + + + + + + +[Next + +arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) +[Previous + +arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.normal_random_ints_fixed_sum.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.normal_random_ints_fixed_sum.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3c9d86b141d8b8df84f25105c3b736a8c3fdcd7a --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.normal_random_ints_fixed_sum.md.txt @@ -0,0 +1,416 @@ + + + + + + +arthurai.util.normal\_random\_ints\_fixed\_sum - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](#) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util.normal\_random\_ints\_fixed\_sum[#](#arthurai-util-normal-random-ints-fixed-sum "Permalink to this headline") +=========================================================================================================================== + + + + +arthurai.util.normal\_random\_ints\_fixed\_sum(*num\_values*, *total\_sum*, *relative\_std\_dev=0.5*)[#](#arthurai.util.normal_random_ints_fixed_sum "Permalink to this definition") +Return num\_values roughly normally-distributed integers summing to total\_sum. Numbers are first sampled from +the normal distribution, then adjusted to fit the sum. Adjustments are made first by shifting the resulting +distribution to be at least total\_sum, then decrementing a subset of the values to match total\_sum. +:type num\_values: `int` +:param num\_values: number of integers to return +:type total\_sum: `int` +:param total\_sum: total sum the integers returned +:type relative\_std\_dev: `float` +:param relative\_std\_dev: the relative standard deviation (std\_dev / mean) of the initial distribution. +:rtype: `ndarray` +:return: + + + + + + + + +[Next + +arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) +[Previous + +arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.util.value_type_to_python_type.md.txt b/files/arthur-docs-markdown/sdk/arthurai.util.value_type_to_python_type.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2f0a64cc6746081d7b6ab15e5a0e490d454ca844 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.util.value_type_to_python_type.md.txt @@ -0,0 +1,410 @@ + + + + + + +arthurai.util.value\_type\_to\_python\_type - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](#) + + [arthurai.version](arthurai.version.html) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.util.value\_type\_to\_python\_type[#](#arthurai-util-value-type-to-python-type "Permalink to this headline") +===================================================================================================================== + + + + +arthurai.util.value\_type\_to\_python\_type(*value\_type*)[#](#arthurai.util.value_type_to_python_type "Permalink to this definition") + +Return type +`Type` + + + + + + + + + + +[Next + +arthurai.version](arthurai.version.html) +[Previous + +arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/sdk/arthurai.version.md.txt b/files/arthur-docs-markdown/sdk/arthurai.version.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..f8499cf470e3e8d0b39c39df6292e47c7ebb3102 --- /dev/null +++ b/files/arthur-docs-markdown/sdk/arthurai.version.md.txt @@ -0,0 +1,396 @@ + + + + + + +arthurai.version - Arthur SDK Reference documentation + + + + + + body { + --color-code-background: #f8f8f8; + --color-code-foreground: black; + --color-foreground-primary: #1a0016; + --color-foreground-secondary: #473351; + --color-background-primary: #ffffff; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #e4e0e4; + --color-background-border: #e4e0e4; + --color-inline-code-background: #e4e0e4; + --color-icon: #473351; + --color-toc-item-text: #1a0016; + --color-toc-item-text--active: #473351; + --color-highlight-on-target: #c7fdd1; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #e4e0e4; + + } + @media not print { + body[data-theme="dark"] { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + @media (prefers-color-scheme: dark) { + body:not([data-theme="light"]) { + --color-code-background: #202020; + --color-code-foreground: #d0d0d0; + --color-foreground-primary: #ffffff; + --color-foreground-secondary: #e4e0e4; + --color-background-primary: #1a0016; + --color-background-secondary: #473351; + --color-brand-primary: #b536fb; + --color-api-background: #473351; + --color-background-border: #473351; + --color-inline-code-background: #473351; + --color-icon: #e4e0e4; + --color-toc-item-text: #ffffff; + --color-toc-item-text--active: #e4e0e4; + --color-highlight-on-target: #473351; + --color-brand-content: #329ad7; + --color-sidebar-background: #473351; + --color-sidebar-link-text: #ffffff; + --color-sidebar-link-text--top-level: #c7fdd1; + --color-sidebar-item-background--hover: #ffffff; + --color-sidebar-text--hover: #1a0016; + --color-sidebar-search-text: #ffffff; + --color-sidebar-search-border: #e4e0e4; + --color-sidebar-search-foreground: #1a0016; + --color-sidebar-search-foreground--inactive: #e4e0e4; + --color-sidebar-search-background--focus: #ffffff; + --font-stack: Graphik, sans-serif; + --font-stack--monospace: IBM Plex Mono, monospace; + --color-table-header-background: #473351; + + } + } + } + + + + document.body.dataset.theme = localStorage.getItem("theme") || "auto"; + + + +Contents + + + + + +Menu + + + + + + + +Expand + + + + + +Light mode + + + + + + + + + + + + + +Dark mode + + + + + + +Auto light/dark mode + + + + + + + + + + + + + + +Hide navigation sidebar + + +Hide table of contents sidebar + + + + + +Toggle site navigation sidebar + + + + +[Arthur SDK Reference documentation](../index.html) + + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + + +[![Light Logo](../_static/images/dark-mode-logo.svg) +![Dark Logo](../_static/images/dark-mode-logo.svg)](../index.html) + + + + + +* [Arthur Docs](https://docs.arthur.ai) +* [SDK Home](../index.html) +* [Permissions by Function](../permissions.html) +* [arthurai](arthurai.html)Toggle child pages in navigation + + [arthurai.client](arthurai.client.html)Toggle child pages in navigation + - [arthurai.client.apiv3](arthurai.client.apiv3.html) + - [arthurai.client.client](arthurai.client.client.html)Toggle child pages in navigation + * [arthurai.client.client.new\_requests\_client](arthurai.client.client.new_requests_client.html) + * [arthurai.client.client.ArthurAI](arthurai.client.client.ArthurAI.html) + - [arthurai.client.helper](arthurai.client.helper.html)Toggle child pages in navigation + * [arthurai.client.helper.construct\_url](arthurai.client.helper.construct_url.html) + * [arthurai.client.helper.get\_arthur\_internal\_user\_org](arthurai.client.helper.get_arthur_internal_user_org.html) + * [arthurai.client.helper.get\_auth\_info](arthurai.client.helper.get_auth_info.html) + * [arthurai.client.helper.get\_current\_org](arthurai.client.helper.get_current_org.html) + * [arthurai.client.helper.user\_login](arthurai.client.helper.user_login.html) + - [arthurai.client.http](arthurai.client.http.html)Toggle child pages in navigation + * [arthurai.client.http.arthur](arthurai.client.http.arthur.html)Toggle child pages in navigation + + [arthurai.client.http.arthur.ArthurHTTPClient](arthurai.client.http.arthur.ArthurHTTPClient.html) + * [arthurai.client.http.base](arthurai.client.http.base.html)Toggle child pages in navigation + + [arthurai.client.http.base.AbstractHTTPClient](arthurai.client.http.base.AbstractHTTPClient.html) + * [arthurai.client.http.requests](arthurai.client.http.requests.html)Toggle child pages in navigation + + [arthurai.client.http.requests.HTTPClient](arthurai.client.http.requests.HTTPClient.html) + - [arthurai.client.validation](arthurai.client.validation.html)Toggle child pages in navigation + * [arthurai.client.validation.validate\_multistatus\_response\_and\_get\_failures](arthurai.client.validation.validate_multistatus_response_and_get_failures.html) + * [arthurai.client.validation.validate\_response\_status](arthurai.client.validation.validate_response_status.html) + + [arthurai.common](arthurai.common.html)Toggle child pages in navigation + - [arthurai.common.constants](arthurai.common.constants.html)Toggle child pages in navigation + * [arthurai.common.constants.AccuracyMetric](arthurai.common.constants.AccuracyMetric.html) + * [arthurai.common.constants.Enrichment](arthurai.common.constants.Enrichment.html) + * [arthurai.common.constants.ImageContentType](arthurai.common.constants.ImageContentType.html) + * [arthurai.common.constants.ImageResponseType](arthurai.common.constants.ImageResponseType.html) + * [arthurai.common.constants.InputType](arthurai.common.constants.InputType.html) + * [arthurai.common.constants.ListableStrEnum](arthurai.common.constants.ListableStrEnum.html) + * [arthurai.common.constants.OutputType](arthurai.common.constants.OutputType.html) + * [arthurai.common.constants.Role](arthurai.common.constants.Role.html) + * [arthurai.common.constants.Stage](arthurai.common.constants.Stage.html) + * [arthurai.common.constants.TextDelimiter](arthurai.common.constants.TextDelimiter.html) + * [arthurai.common.constants.ValueType](arthurai.common.constants.ValueType.html) + - [arthurai.common.exceptions](arthurai.common.exceptions.html)Toggle child pages in navigation + * [arthurai.common.exceptions.arthur\_excepted](arthurai.common.exceptions.arthur_excepted.html) + - [arthurai.common.log](arthurai.common.log.html)Toggle child pages in navigation + * [arthurai.common.log.disable\_debug\_logging](arthurai.common.log.disable_debug_logging.html) + * [arthurai.common.log.enable\_debug\_logging](arthurai.common.log.enable_debug_logging.html) + * [arthurai.common.log.initialize\_logging](arthurai.common.log.initialize_logging.html) + * [arthurai.common.log.InfoFilter](arthurai.common.log.InfoFilter.html) + + [arthurai.core](arthurai.core.html)Toggle child pages in navigation + - [arthurai.core.alerts](arthurai.core.alerts.html)Toggle child pages in navigation + * [arthurai.core.alerts.Alert](arthurai.core.alerts.Alert.html) + * [arthurai.core.alerts.AlertRule](arthurai.core.alerts.AlertRule.html) + * [arthurai.core.alerts.AlertRuleBound](arthurai.core.alerts.AlertRuleBound.html) + * [arthurai.core.alerts.AlertRuleSeverity](arthurai.core.alerts.AlertRuleSeverity.html) + * [arthurai.core.alerts.AlertStatus](arthurai.core.alerts.AlertStatus.html) + * [arthurai.core.alerts.Metric](arthurai.core.alerts.Metric.html) + * [arthurai.core.alerts.MetricType](arthurai.core.alerts.MetricType.html) + - [arthurai.core.attributes](arthurai.core.attributes.html)Toggle child pages in navigation + * [arthurai.core.attributes.ArthurAttribute](arthurai.core.attributes.ArthurAttribute.html) + * [arthurai.core.attributes.AttributeBin](arthurai.core.attributes.AttributeBin.html) + * [arthurai.core.attributes.AttributeCategory](arthurai.core.attributes.AttributeCategory.html) + - [arthurai.core.auth\_info](arthurai.core.auth_info.html)Toggle child pages in navigation + * [arthurai.core.auth\_info.AuthInfo](arthurai.core.auth_info.AuthInfo.html) + - [arthurai.core.base](arthurai.core.base.html)Toggle child pages in navigation + * [arthurai.core.base.ArthurBaseJsonDataclass](arthurai.core.base.ArthurBaseJsonDataclass.html) + - [arthurai.core.bias](arthurai.core.bias.html)Toggle child pages in navigation + * [arthurai.core.bias.bias\_metrics](arthurai.core.bias.bias_metrics.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_metrics.BiasMetrics](arthurai.core.bias.bias_metrics.BiasMetrics.html) + * [arthurai.core.bias.bias\_wrapper](arthurai.core.bias.bias_wrapper.html)Toggle child pages in navigation + + [arthurai.core.bias.bias\_wrapper.ArthurBiasWrapper](arthurai.core.bias.bias_wrapper.ArthurBiasWrapper.html) + * [arthurai.core.bias.threshold\_mitigation](arthurai.core.bias.threshold_mitigation.html)Toggle child pages in navigation + + [arthurai.core.bias.threshold\_mitigation.Curves](arthurai.core.bias.threshold_mitigation.Curves.html) + + [arthurai.core.bias.threshold\_mitigation.ThresholdMitigation](arthurai.core.bias.threshold_mitigation.ThresholdMitigation.html) + - [arthurai.core.data\_service](arthurai.core.data_service.html)Toggle child pages in navigation + * [arthurai.core.data\_service.DatasetService](arthurai.core.data_service.DatasetService.html) + * [arthurai.core.data\_service.ImageZipper](arthurai.core.data_service.ImageZipper.html) + - [arthurai.core.decorators](arthurai.core.decorators.html)Toggle child pages in navigation + * [arthurai.core.decorators.log\_prediction](arthurai.core.decorators.log_prediction.html) + - [arthurai.core.inferences](arthurai.core.inferences.html)Toggle child pages in navigation + * [arthurai.core.inferences.add\_inference\_metadata\_to\_dataframe](arthurai.core.inferences.add_inference_metadata_to_dataframe.html) + * [arthurai.core.inferences.add\_predictions\_or\_ground\_truth](arthurai.core.inferences.add_predictions_or_ground_truth.html) + * [arthurai.core.inferences.nest\_inference\_and\_ground\_truth\_data](arthurai.core.inferences.nest_inference_and_ground_truth_data.html) + * [arthurai.core.inferences.parse\_stage\_attributes](arthurai.core.inferences.parse_stage_attributes.html) + - [arthurai.core.model\_utils](arthurai.core.model_utils.html)Toggle child pages in navigation + * [arthurai.core.model\_utils.check\_attr\_is\_bias](arthurai.core.model_utils.check_attr_is_bias.html) + * [arthurai.core.model\_utils.check\_has\_bias\_attrs](arthurai.core.model_utils.check_has_bias_attrs.html) + * [arthurai.core.model\_utils.get\_positive\_predicted\_class](arthurai.core.model_utils.get_positive_predicted_class.html) + - [arthurai.core.models](arthurai.core.models.html)Toggle child pages in navigation + * [arthurai.core.models.ArthurModel](arthurai.core.models.ArthurModel.html) + * [arthurai.core.models.ArthurModelGroup](arthurai.core.models.ArthurModelGroup.html) + * [arthurai.core.models.ExplainabilityParameters](arthurai.core.models.ExplainabilityParameters.html) + - [arthurai.core.util](arthurai.core.util.html)Toggle child pages in navigation + * [arthurai.core.util.dataframe\_like\_to\_list\_of\_dicts](arthurai.core.util.dataframe_like_to_list_of_dicts.html) + * [arthurai.core.util.intersection\_is\_non\_empty](arthurai.core.util.intersection_is_non_empty.html) + * [arthurai.core.util.retrieve\_parquet\_files](arthurai.core.util.retrieve_parquet_files.html) + * [arthurai.core.util.standardize\_pd\_obj](arthurai.core.util.standardize_pd_obj.html) + * [arthurai.core.util.update\_column\_in\_list\_of\_dicts](arthurai.core.util.update_column_in_list_of_dicts.html) + * [arthurai.core.util.NumpyEncoder](arthurai.core.util.NumpyEncoder.html) + - [arthurai.core.viz](arthurai.core.viz.html)Toggle child pages in navigation + * [arthurai.core.viz.style](arthurai.core.viz.style.html) + * [arthurai.core.viz.utils](arthurai.core.viz.utils.html)Toggle child pages in navigation + + [arthurai.core.viz.utils.get\_pred\_and\_gt\_attrs](arthurai.core.viz.utils.get_pred_and_gt_attrs.html) + + [arthurai.core.viz.utils.savgol\_filter](arthurai.core.viz.utils.savgol_filter.html) + * [arthurai.core.viz.visualizer](arthurai.core.viz.visualizer.html)Toggle child pages in navigation + + [arthurai.core.viz.visualizer.DataVisualizer](arthurai.core.viz.visualizer.DataVisualizer.html) + + [arthurai.explainability](arthurai.explainability.html)Toggle child pages in navigation + - [arthurai.explainability.arthur\_explainer](arthurai.explainability.arthur_explainer.html)Toggle child pages in navigation + * [arthurai.explainability.arthur\_explainer.ArthurExplainer](arthurai.explainability.arthur_explainer.ArthurExplainer.html) + * [arthurai.explainability.arthur\_explainer.EmptyLimeExplanation](arthurai.explainability.arthur_explainer.EmptyLimeExplanation.html) + - [arthurai.explainability.explanation\_packager](arthurai.explainability.explanation_packager.html)Toggle child pages in navigation + * [arthurai.explainability.explanation\_packager.ExplanationPackager](arthurai.explainability.explanation_packager.ExplanationPackager.html) + - [arthurai.explainability.validation](arthurai.explainability.validation.html)Toggle child pages in navigation + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_dataframe](arthurai.explainability.validation.validate_predicted_attribute_order_matches_dataframe.html) + * [arthurai.explainability.validation.validate\_predicted\_attribute\_order\_matches\_remote](arthurai.explainability.validation.validate_predicted_attribute_order_matches_remote.html) + + [arthurai.util](arthurai.util.html)Toggle child pages in navigation + - [arthurai.util.format\_timestamp](arthurai.util.format_timestamp.html) + - [arthurai.util.format\_timestamps](arthurai.util.format_timestamps.html) + - [arthurai.util.generate\_timestamps](arthurai.util.generate_timestamps.html) + - [arthurai.util.is\_valid\_datetime\_string](arthurai.util.is_valid_datetime_string.html) + - [arthurai.util.normal\_random\_ints\_fixed\_sum](arthurai.util.normal_random_ints_fixed_sum.html) + - [arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + [arthurai.version](#) + + + + + + + + + + +[Back to top](#) + + + +Toggle Light / Dark / Auto color theme + + + + + + +Toggle table of contents sidebar + + + + + +arthurai.version[#](#module-arthurai.version "Permalink to this headline") +========================================================================== + + + + + + + +[Previous + +arthurai.util.value\_type\_to\_python\_type](arthurai.util.value_type_to_python_type.html) + + + + + Copyright © 2022, Arthur + + Made with [Sphinx](https://www.sphinx-doc.org/) and [@pradyunsg](https://pradyunsg.me)'s + + [Furo](https://github.com/pradyunsg/furo) + + + + + + + + + + + + + + + + + diff --git a/files/arthur-docs-markdown/user-guide/.DS_Store b/files/arthur-docs-markdown/user-guide/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..beab618a2724b56c6a21e97407fc5c43ac9c5d92 Binary files /dev/null and b/files/arthur-docs-markdown/user-guide/.DS_Store differ diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/aggregation_functions.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/aggregation_functions.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..51b9ab5428a091a7f9b3ee856bb12165db7212bc --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/aggregation_functions.md.txt @@ -0,0 +1,1130 @@ +# Aggregation Functions + +For an explanation of nested functions, see the guide {doc}`here `. + +### Average +Take the average of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "avg", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "avg", + "alias": "avgAge", + "parameters": { + "property": "age" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "avgAge": 55.45 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Average of Absolute Values +Take the average of absolute values of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "avgAbs", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "avgAbs", + "alias": "avgafloat", + "parameters": { + "property": "afloat" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "avgafloat": 55.45 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Max +Take the max of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "max", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "max", + "alias": "maxAge", + "parameters": { + "property": "age" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "maxAge": 55.45 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Min +Take the min of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "min", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "min", + "alias": "minAge", + "parameters": { + "property": "age" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "minAge": 17 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Sum +Take the sum of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "sum", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "sum", + "alias": "sumAge", + "parameters": { + "property": "age" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "sumAge": 1745 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Variance +Take the variance of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "variance", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "variance", + "alias": "varAge", + "parameters": { + "property": "age" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "varAge": 10.234 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Count +Count a property. + +Query Request: +```json +{ + "select": [ + { + "function": "count", + "alias": " [optional string]" + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [int]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "count" + } + ], + "filter": [ + { + "property": "income", + "comparator": "lt", + "value": 90000 + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "count": 5432 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Count If +Conditionally count a property. + +Query Request: +```json +{ + "select": [ + { + "function": "countIf", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "comparator": " [string]", + "value": "" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [int]" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: +```json +{ + "select": [ + { + "function": "countIf", + "alias": "michigan_count", + "parameters": { + "property": "state", + "comparator": "eq", + "value": "michigan" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "michigan_count": 5432 + } + ] +} +``` + +[back to top](#aggregation-functions) + +### Categories Count +Count the number of categories of a property. To be used for discrete features. + +Query Request: +```json +{ + "select": [ + { + "function": "categoriesCount", + "alias": " [optional string]", + "parameters": { + "property": " [string]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [int]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "categoriesCount", + "alias": "categoriesCountZipcode", + "parameters": { + "property": "zipcode" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "categoriesCountZipcode": 732 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Rate +Calculates the rate of a condition on a column. + +Query Request: +```json +{ + "select": [ + { + "function": "rate", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "comparator": " [string]", + "value": "" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: Calculate the positive predictive rate, with predictions classified as positive when `pos_class` above .5 (standard definition of positive predictive rate). + +```json +{ + "select": [ + { + "function": "rate", + "alias": "pos_rate", + "parameters": { + "property": "pos_class", + "comparator": "gt", + "value": 0.5 + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "pos_rate": "0.1" + } + ] +} +``` + +[back to top](#aggregation-functions) + +### Distribution +Return the distribution of a column with a specified number of bins. + +You may specify one of either `num_bins` or `bin_thresholds`. + +For `num_bins,`, if there is not enough data, fewer than the specified number of bins will be returned. + +For `bin_thresholds`, there will be a bucket below your lowest bin and a bucket above your highest bin, i.e. `n+1` buckets when supplied `n` thresholds. + +Query Request with `num_bins`: +```json +{ + "select": [ + { + "function": "distribution", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "num_bins": " [int]" + } + } + ] +} +``` + +Query Request with `bin_thresholds`: +```json +{ + "select": [ + { + "function": "distribution", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "bin_thresholds": " [List[int]]" + } + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": [ + { + "lower": " [float]", + "upper": " [float]", + "count": " [float]" + } + ] + } + ] +} +``` + +Lower bounds are inclusive while upper bounds are exclusive, so a bucket response like this: +```json +{ + "lower": 30, + "upper": 50, + "count": " [float]" +} +``` +would include values such as 30, 40, or 49.999, but not 50. + +*** + +Sample Request with `num_bins`: +```json +{ + "select": [ + { + "function": "distribution", + "parameters": { + "property": "FICO_predicted", + "num_bins": 50 + } + } + ] +} +``` +Sample Response with `num_bins`: +```json +{ + "query_result": [ + { + "distribution": [ + { + "lower": 500, + "upper": 600, + "count": 1000 + }, + { + "lower": 600, + "upper": 700, + "count": 5000 + }, + { + "lower": 700, + "upper": 800, + "count": 2000 + }, + { + "lower": 800, + "upper": 850, + "count": 550 + } + ] + } + ] +} +``` + +Sample Request with `bin_thresholds`: +```json +{ + "select": [ + { + "function": "distribution", + "parameters": { + "property": "FICO_predicted", + "bin_thresholds": [600, 700] + } + } + ] +} +``` +Sample Response with `bin_thresholds`: +```json +{ + "query_result": [ + { + "distribution": [ + { + "upper": 600, + "count": 1000 + }, + { + "lower": 600, + "upper": 700, + "count": 5000 + }, + { + "lower": 700, + "count": 2550 + } + ] + } + ] +} +``` +[back to top](#aggregation-functions) + +### Arg Max +Take the value of a property at which a different property as at its maximum. + +Query Request: +```json +{ + "select": [ + { + "function": "argMax", + "alias": " [optional string]", + "parameters": { + "argument": " [string or nested]", + "value": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [constant]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "argMax", + "alias": "mostExpensiveZipCode", + "parameters": { + "argument": "zipCode", + "value": "homePrice" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "mostExpensiveZipCode": 94027 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Arg Min +Take the value of a property at which a different property as at its minimum. + +Query Request: +```json +{ + "select": [ + { + "function": "argMin", + "alias": " [optional string]", + "parameters": { + "argument": " [string or nested]", + "value": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [constant]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "argMin", + "alias": "leastExpensiveZipCode", + "parameters": { + "argument": "zipCode", + "value": "homePrice" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "leastExpensiveZipCode": 46953 + } + ] +} +``` +[back to top](#aggregation-functions) + +### Any If +Returns the selected property for any row which matches the provided condition. A common use case for this function is +{doc}`querying data with unique identifiers `. + +Query Request: +```json +{ + "select": [ + { + "function": "anyIf", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "comparator": " [string]", + "value": "", + "result": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [constant]" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: +```json +{ + "select": [ + { + "function": "anyIf", + "alias": "some_michigan_price", + "parameters": { + "property": "state", + "comparator": "eq", + "value": "michigan", + "result": "homePrice" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "some_michigan_price": 459312 + } + ] +} +``` + +[back to top](#aggregation-functions) + +(aggregation_functions_regional_feature_importance)= +### Regional Feature Importance +Returns the regional importance score for a particular attribute. This is the average of the absolute value of the +explainability value for all the inferences. This is only available if explainability has been +{ref}`enabled ` for the model. + +Query Request: +```json +{ + "select": [ + { + "function": "regionalFeatureImportance", + "alias": " [optional string]", + "parameters": { + "attribute_name": " [string]", + "predicted_attribute_name": " [string]", + "explanation_algorithm": "[lime|shap]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` +Sample Request: +```json +{ + "select": [ + { + "function": "regionalFeatureImportance", + "parameters": { + "attribute_name": "AGE", + "predicted_attribute_name": "prediction_0", + "explanation_algorithm": "lime" + } + } + ], + "filter": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-12-01T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-12-22T11:00:00Z" + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "AGE": 0.001406118694451489 + } + ] +} +``` +[back to top](#aggregation-functions) + +(aggregation_functions_regional_feature_importances)= +### Regional Feature Importances +Returns the regional importance scores for all of the pipeline input attributes. This is the average of the absolute value of the explainability value for all the inferences for each pipeline input attribute. This is only available if explainability has been {ref}`enabled ` for the model. + +Query Request: +```json +{ + "select": [ + { + "function": "regionalFeatureImportances", + "alias": " [optional string]", + "parameters": { + "predicted_attribute_name": " [string]", + "explanation_algorithm": "[lime|shap]" + } + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [float]", + "": " [float]", + "": " [float]", + "": " [float]", + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "regionalFeatureImportances", + "parameters": { + "predicted_attribute_name": "prediction_0", + "explanation_algorithm": "lime" + } + } + ], + "filter": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-12-01T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-12-22T11:00:00Z" + } + ] +} +``` + +Sample Response: +```json +{ + "query_result": [ + { + "explainer_attribute": "PAY_0", + "regionalFeatureImportance": 0.055036517803945396 + }, + { + "explainer_attribute": "PAY_2", + "regionalFeatureImportance": 0.026880464089676884 + }, + { + "explainer_attribute": "PAY_3", + "regionalFeatureImportance": 0.024027941129616155 + }, + { + "explainer_attribute": "LIMIT_BAL", + "regionalFeatureImportance": 0.022367882999425544 + }, + { + "explainer_attribute": "PAY_AMT2", + "regionalFeatureImportance": 0.019145911247181836 + }, + { + "explainer_attribute": "PAY_AMT1", + "regionalFeatureImportance": 0.019052984358794038 + }, + { + "explainer_attribute": "PAY_AMT3", + "regionalFeatureImportance": 0.012942233755875516 + }, + { + "explainer_attribute": "PAY_5", + "regionalFeatureImportance": 0.011911442095349226 + }, + { + "explainer_attribute": "PAY_4", + "regionalFeatureImportance": 0.010464962507962139 + }, + { + "explainer_attribute": "PAY_6", + "regionalFeatureImportance": 0.00891260261770653 + }, + { + "explainer_attribute": "BILL_AMT4", + "regionalFeatureImportance": 0.007211523900878019 + }, + { + "explainer_attribute": "BILL_AMT5", + "regionalFeatureImportance": 0.006279087267628024 + }, + { + "explainer_attribute": "BILL_AMT1", + "regionalFeatureImportance": 0.006221344024007549 + }, + { + "explainer_attribute": "PAY_AMT4", + "regionalFeatureImportance": 0.005310133724715099 + }, + { + "explainer_attribute": "PAY_AMT6", + "regionalFeatureImportance": 0.004135643379284112 + }, + { + "explainer_attribute": "MARRIAGE", + "regionalFeatureImportance": 0.004089899824740581 + }, + { + "explainer_attribute": "EDUCATION", + "regionalFeatureImportance": 0.003931984513777395 + }, + { + "explainer_attribute": "PAY_AMT5", + "regionalFeatureImportance": 0.0033734464617669853 + }, + { + "explainer_attribute": "SEX", + "regionalFeatureImportance": 0.0029222783744727687 + }, + { + "explainer_attribute": "BILL_AMT6", + "regionalFeatureImportance": 0.002707692309829875 + }, + { + "explainer_attribute": "BILL_AMT2", + "regionalFeatureImportance": 0.001955133839877692 + }, + { + "explainer_attribute": "BILL_AMT3", + "regionalFeatureImportance": 0.001779632159224476 + }, + { + "explainer_attribute": "AGE", + "regionalFeatureImportance": 0.001406118694451494 + } + ] +} +``` +[back to top](#aggregation-functions) diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/composing_functions.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/composing_functions.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..36e47224cb82d15601638defd8db86e7d94c2762 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/composing_functions.md.txt @@ -0,0 +1,122 @@ +# Composing Functions (Advanced Usage) + +To see functions you can use with this syntax, +checkout the {doc}`aggregation functions ` +and the {doc}`transformation functions `. + +Any function with a parameter with the type signature `[string or nested]` +is able to accept the following as a value: +1. a string constant that represents a property of the model +1. an object of the form: + ```json + { + "alias_ref": "string", + "nested_function": {"...": "..."} + } + ``` + + Only one of `alias_ref` or `nested_function` may be present at a time. See the following + explanations of each. + +## Alias References +The `alias_ref` field allows specifying another selected column's alias +to use as input to the function. This example uses an `alias_ref` to pull in another column +to the `add` function: +```json +{ + "select": [ + { + "function": "abs", + "alias": "absLoan", + "parameters": { + "property": "loan" + } + }, + { + "function": "add", + "alias": "plus2", + "parameters": { + "left": 2, + "right": { + "alias_ref": "absLoan" + } + } + } + ] +} +``` + +This request returns: +```json +{ + "query_result": [ + { + "absLoan": 55.45, + "plus2": 57.45 + } + ] +} +``` + +## Nested Functions +The `nested_function` field allows specifying another function definition +to use as input. Here's an example of how to calculate absolute error for +a regression model. In this example, we pass the nested `subtract` function as +input to the `abs` function via the `nested_function` object for the `property` +parameter of `abs`: +```json +{ + "select": [ + { + "function": "abs", + "alias": "abs_error", + "parameters": { + "property": { + "nested_function": { + "function": "subtract", + "alias": "error", + "parameters": { + "left": "Predicted_FICO_Score", + "right": { + "alias_ref": "ground_truth" + } + } + } + } + } + }, + { + "property": "Predicted_FICO_Score" + }, + { + "property": "Consumer_Credit_Score", + "alias": "ground_truth" + } + ] +} +``` + +This query returns: +```json +{ + "query_result": [ + { + "Consumer_Credit_Score": 660, + "Predicted_FICO_Score": 688.10004, + "abs_error": 28.100040000000035 + }, + { + "Consumer_Credit_Score": 663, + "Predicted_FICO_Score": 681, + "abs_error": 18 + }, + "..." + ] +} +``` + +```{note} If you use the same function multiple times in a query, you need to give each one a distinct "alias". Otherwise, the names will conflict. +``` + + + diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/data_drift.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/data_drift.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..da40dd3a782724663b3039d0790714a78dbc83a8 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/data_drift.md.txt @@ -0,0 +1,751 @@ +# Data Drift + +## Querying Drift in Python + +The basic format of a drift query using the Python SDK involves specifying that the +`query_type` parameter has the value 'drift': +```python +query = {...} + +arthur_model.query(query, query_type='drift') +``` + +## Data Drift Endpoint + +Data drift has a dedicated endpoint at `/models/{model_id}/inferences/query/data_drift`. + +Returns the data drift metric between a `base` dataset with a `target` dataset. This endpoint can support up to 100 properties in one request. + +* `num_bins` - Specifies the granularity of bucketing for continuous distributions and will be ignored if the attribute is categorical. +* `metric` - Specify one metric among {ref}`the data drift metrics Arthur offers `. +* `filter` - Optional blocks specific to either reference or inference set and specify which data should be used in the data drift calculation. +* `group_by` - Global and applies to both the base and target data. +* `rollup` - Optional parameter that will aggregate the calculated data drift value by the supported time dimension. + +For `HypothesisTest`, the returned value is transformed as -log_10(P_value) to maintain directional parity with the other data drift metrics. That is, lower P_value is more significant and implies data drift, reflected in a higher -log_10(P_value). Further mathematical details are in the {ref}`glossary . + +Query Request: +```json +{ + "properties": [ + " [string]", + " [string]", + " [string]" + ], + "num_bins": " [int]", + "metric": "[PSI|KLDivergence|JSDivergence|HellingerDistance|HypothesisTest]", + "base": { + "source": "[inference|reference]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "target": { + "source": "[inference|reference|ground_truth]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "group_by [Optional]": [ + { + "property": " [string]" + } + ], + "rollup [Optional]": "minute|hour|day|month|year|batch_id" +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [float]", + "": " [float]", + "": " [float]", + "": " [string|int|null]", + "rollup": " [string|null]" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +#### Example: Reference vs. Inference + +Sample Request: Calculate data drift for males, grouped by country, rolled up by hour. + +```json +{ + "properties": [ + "age" + ], + "num_bins": 10, + "metric": "PSI", + "base": { + "source": "reference", + "filter": [ + { + "property": "gender", + "comparator": "eq", + "value": "male" + } + ] + }, + "target": { + "source": "inference", + "filter": [ + { + "property": "gender", + "comparator": "eq", + "value": "male" + }, + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-07-23T10:00:00Z" + } + ] + }, + "group_by": [ + { + "property": "country" + } + ], + "rollup": "hour" +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "age": 2.3, + "country": "Canada", + "rollup": "2020-07-22T10:00:00Z" + }, + { + "age": 2.4, + "country": "United States", + "rollup": "2020-07-22T10:00:00Z" + } + ] +} +``` + +### Example: Inference vs. Inference + +Sample Request: Compare data drift between two batches, with no grouping, no filters, and no rollups. + +```json +{ + "properties": [ + "age" + ], + "num_bins": 10, + "metric": "PSI", + "base": { + "source": "inference", + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": "5" + } + ] + }, + "target": { + "source": "inference", + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": "6" + } + ] + } +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "age": 2.3 + } + ] +} +``` + +[back to top](#data-drift) + +### Example: Reference vs. Ground Truth + +Sample Request: Calculate data drift for individual ground truth class prediction probabilities, rolled up by hour. + +```json +{ + "properties": [ + "gt_1" + ], + "num_bins": 10, + "metric": "PSI", + "base": { + "source": "reference" + }, + "target": { + "source": "ground_truth", + "filter": [ + { + "property": "ground_truth_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "ground_truth_timestamp", + "comparator": "lt", + "value": "2020-07-23T10:00:00Z" + } + ] + }, + "rollup": "hour" +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "gt_1": 0.03, + "rollup": "2020-07-22T10:00:00Z" + }, + { + "gt_1": 0.4, + "rollup": "2020-07-22T11:00:00Z" + } + ] +} +``` + +[back to top](#data-drift) + + +## Data Drift PSI Bucket Table Values + +This metric has a dedicated endpoint at `/models/{model_id}/inferences/query/data_drift_psi_bucket_calculation_table`. + +Returns the [PSI](https://scholarworks.wmich.edu/cgi/viewcontent.cgi?article=4249&context=dissertations) scores by bucket using the reference set data. This query for this endpoint omits the need for `metric` and takes in a single `property` but otherwise is identical to the [data drift endpoint](#data-drift-endpoint) + +Note when using this endpoint with categorical features, the `bucket_min` and `bucket_max` fields will not be +returned in the response. Instead, the `bucket` field will contain the category name. + +Query Request: +```json +{ + "property": " [string]", + "num_bins": " [int]", + "base": { + "source": "[inference|reference]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "target": { + "source": "[inference|reference]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "group_by [Optional]": [ + { + "property": " [string]" + } + ], + "rollup [Optional]": "minute|hour|day|month|year|batch_id" +} +``` +Query Response: +```json +{ + "query_result": [ + { + "bucket": "string", + "rollup": "string|null", + "group_by_property_1": "string|null", + "base_bucket_max": "number", + "base_bucket_min": "number", + "base_count_per_bucket": "number", + "base_ln_probability_per_bucket": "number", + "base_probability_per_bucket": "number", + "base_total": "number", + "target_bucket_max": "number", + "target_bucket_min": "number", + "target_count_per_bucket": "number", + "target_ln_probability_per_bucket": "number", + "target_probability_per_bucket": "number", + "target_total": "number", + "probability_difference": "number", + "ln_probability_difference": "number", + "psi": "number" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: Calculate data drift bucket components for males, grouped by country, rolled up by hour. +```json +{ + "property": "age", + "num_bins": 2, + "base": { + "source": "reference", + "filter": [ + { + "property": "gender", + "comparator": "eq", + "value": "male" + } + ] + }, + "target": { + "source": "inference", + "filter": [ + { + "property": "gender", + "comparator": "eq", + "value": "male" + }, + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-07-23T10:00:00Z" + } + ] + }, + "group_by": [ + { + "property": "country" + } + ], + "rollup": "hour" +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "bucket": "bucket_1", + "rollup": "2020-01-01T00:00:00Z", + "country": "Canada", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + }, + { + "bucket": "bucket_2", + "rollup": "2020-01-01T00:00:00Z", + "country": "United States", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + }, + { + "bucket": "bucket_1", + "rollup": "2020-01-01T01:00:00Z", + "country": "Canada", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + }, + { + "bucket": "bucket_2", + "rollup": "2020-01-01T01:00:00Z", + "country": "United States", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + } + ] +} +``` + +Sample Request: Compare data drift bucket components between two batches, with no grouping, no filters, and no rollups. + +```json +{ + "property": "age", + "num_bins": 10, + "base": { + "source": "inference", + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": "5" + } + ] + }, + "target": { + "source": "inference", + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": "6" + } + ] + } +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "bucket": "bucket_1", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + }, + { + "bucket": "bucket_2", + "base_bucket_max": 0.9999971182990177, + "base_bucket_min": 0.5009102069226075, + "base_count_per_bucket": 4988, + "base_ln_probability_per_bucket": -0.6955500651756032, + "base_probability_per_bucket": 0.4988, + "base_total": 10000, + "target_bucket_max": 0.9999971182990177, + "target_bucket_min": 0.5009102069226075, + "target_count_per_bucket": 2487, + "target_ln_probability_per_bucket": -0.6701670131762315, + "target_probability_per_bucket": 0.5116231228142357, + "target_total": 4861, + "probability_difference": -0.012823122814235699, + "ln_probability_difference": -0.025383051999371742, + "psi": 0.00032548999318807485 + } + ] +} +``` + +[back to top](#data-drift) + +## Data Drift for Classification Outputs + +For classification outputs, one may want to examine drift among a collection of different classes, i.e. the system of outputs, instead of the drift of the probability predictions of a single class. The query uses one of `"predicted_classes": ["*"]` or `"ground_truth_classes": ["*"]` but otherwise is identical to a standard data drift query. Rather than using the star operator to select all prediction or ground truth classes, respectively, in a model, a list of string classes can be provided for looking at drift of a subset of multiclass outputs. + +* `predicted_classes` - Specifies which prediction classes to use for `predictedClass` data drift. +* `ground_truth_classes` - Specifies which prediction classes to use for `groundTruthClass` data drift. + +`properties` can be included in the same query as long as the target `source` corresonds to the classification output tag. For example, one can query drift on input attributes and `predictedClass` in the same query with target `source` of `inference`; one can query drift on individual ground truth labels and `groundTruthClass` in the same query with target `source` of `ground_truth`. + +Query Request: +```json +{ + "properties [Optional]": [ + " [string]", + " [string]", + " [string]" + ], + "[predicted_classes|ground_truth_classes]": [ + " [string]" + " [string]" + ], + "num_bins": " [int]", + "metric": "[PSI|KLDivergence|JSDivergence|HellingerDistance|HypothesisTest]", + "base": { + "source": "[inference|reference]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "target": { + "source": "[inference|reference|ground_truth]", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "group_by [Optional]": [ + { + "property": " [string]" + } + ], + "rollup [Optional]": "minute|hour|day|month|year|batch_id" +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [float]", + "": " [float]", + "": " [float]", + "[predictedClass|groundTruthClass]": " [float]", + "": " [string|int|null]", + "rollup": " [string|null]" + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: Calculate data drift on all prediction classes. +```json +{ + "predicted_classes": [ + "*" + ], + "num_bins": 20, + "base": { + "source": "reference" + }, + "target": { + "source": "inference" + }, + "metric": "PSI" +} +``` + +Sample Response: +```json +{ + "query_result": [ + { + "predictedClass": 0.021 + } + ] +} +``` + +Sample Request: Calculate data drift on ground truth using the first and third ground truth classes. +```json +{ + "predicted_classes": [ + "gt_1", + "gt_3" + ], + "num_bins": 20, + "base": { + "source": "reference" + }, + "target": { + "source": "ground_truth" + }, + "metric": "PSI" +} +``` + +Sample Response: +```json +{ + "query_result": [ + { + "groundTruthClass": 0.021 + } + ] +} +``` + +[back to top](#data-drift) + +(automated_data_drift_thresholds)= +## Automated Data Drift Thresholds + +What is a sufficiently high data drift value to suggest that the target data has actually drifted from the base data? For `HypothesisTest`, we can reverse engineer -log_10(P_value) and plug in the conventional .05 alpha level to establish a lower bound of -log_10(.05). + +For the other data drift metrics, it is not sufficient to pin a constant. We abstract this away for the user and allow queries to obtain automatically generated data drift thresholds (lower bounds) based on a model's data. These thresholds can be used in alerting. For more information see: [Automating Data Drift Thresholding in Machine Learning Systems](https://arthur.ai/blog/automating-data-drift-thresholding-in-machine-learning-systems). + +The query uses `"metric": "Thresholds"` and does not require nor use `"target"` and `"rollup"` fields but otherwise is identical to a standard data drift query. + +Query Request: +```json +{ + "properties": [ + " [string]", + " [string]", + " [string]" + ], + "num_bins": " [int]", + "metric": "Thresholds", + "base": { + "source": "reference", + "filter [Optional]": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [string|int|float]" + } + ] + }, + "group_by [Optional]": [ + { + "property": " [string]" + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": { + "HellingerDistance": " [float]", + "JSDivergence": " [float]", + "KLDivergence": " [float]", + "PSI": " [float]" + }, + "": { + "HellingerDistance": " [float]", + "JSDivergence": " [float]", + "KLDivergence": " [float]", + "PSI": " [float]" + } + + } + ] +} +``` + +See {ref}`endpoint_overview_filter_comparators` for a list of valid comparators. + +*** + +Sample Request: +```json +{ + "properties": [ + "AGE" + ], + "num_bins": 20, + "base": { + "source": "reference" + }, + "metric": "Thresholds" +} +``` + +Sample Response: +```json +{ + "query_result": [ + { + "AGE": { + "HellingerDistance": 0.00041737395239735647, + "JSDivergence": 2.959228131592643, + "KLDivergence": 0.001893866910388703, + "PSI": 0.0018945640055550161 + } + } + ] +} +``` + +[back to top](#data-drift) diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/endpoint_overview.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/endpoint_overview.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..39c88a24010aeb03fad1670c83104118556ee9e7 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/endpoint_overview.md.txt @@ -0,0 +1,467 @@ +# Endpoint Overview + +## Overview + +The query endpoint expects a body that represents a query with the following keys: + +* `select` (required) +* `from` (optional) +* `subquery` (optional) +* `filter` (optional) +* `group_by` (optional) +* `order_by` (optional) + +### Property Types + +There are 2 types of properties that can be returned in the query response: + +1. "regular" properties - to select all of these at once time, you can use the `*` string + * include all of the model's attributes + * `inference_timestamp` + * `received_timestamp` + * `inference_id` + * `partner_inference_id` + * `ground_truth_timestamp` (if ground truth is included) + * `batch_id` (if batch model) +2. "enriched" properties - you must specify these by name to include them in the response and use the `from` + value `enriched`: + * `anomaly_score` + * `lime_importance` + * `shap_importance` + +### 'From' Sources + +There are 3 valid values for the `from` field: + +1. `inference` - The latest, raw inference data sent to the platform. This is the default. +2. `enriched` - Every value from the `inference` data, with additional fields for anomaly scores and explanations. This + data has some insert latency compared to the raw table. +3. `reference` - The reference data set uploaded for the model. + +(endpoint_overview_filter_field)= +### Filter Field + +The `filter` field contains a list of filters to apply to your query. It takes the form: + +```json +{ + "filter": [ + { + "property": " [string]", + "comparator": " [string]", + "value": " [any]" + }, + "..." + ] +} +``` + +(endpoint_overview_filter_comparators)= +#### Filter Comparators + +The following filter comparators are available: + +* `eq` - Filters where the property field equals the value field. +* `ne` - Filters where the property field is not equal to the value field. +* `lt` - Filters where the property field is less than the value field. Only valid for number values. +* `gt` - Filters where the property field is greater than the value field. Only valid for number values. +* `lte` - Filters where the property field is less than or equal to the value field. Only valid for number values. +* `gte` - Filters where the property field is greater than or equal to the value field. Only valid for number values. +* `in` - Filters where the property field is equal to any value in a list of possible values +* `like` - Filters where the property field is like the value field. This filter is only valid for property types of + unstructured text. +* `NotNull` - Filters where the property field is not null. Value field should be empty. +* `IsNull` - Filters where the property field is null. Value field should be empty. + +### Object Detection Fields + +Computer Vision models with an Output Type of `Object Detection` have some special fields you can use when querying. + +Bounding boxes are sent using the following form: `[class_id, confidence, top_left_x, top_left_y, width, height]`. While +the fields aren't named when sending data, you can access these nested fields when querying. + +Using the following model as an example: + +``` +InputType: Image +OutputType: ObjectDetection +Attributes: + name stage value_type +0 image PIPELINE_INPUT IMAGE +1 label GROUND_TRUTH BOUNDING_BOX +2 objects_detected PREDICTED_VALUE BOUNDING_BOX +``` + +Example query fetching all bounding box fields + +```json +{ + "selects": [ + { + "property": "inference_id" + }, + { + "property": "objects_detected" + } + ] +} +``` + +The reponse will have 1 object per bounding box. + +```json +{ + "query_result": [ + { + "inference_id": "1", + "objects_detected.class_id": 0, + "objects_detected.confidence": 0.6, + "objects_detected.top_left_x": 23, + "objects_detected.top_left_y": 45, + "objects_detected.width": 20, + "objects_detected.height": 30 + }, + { + "inference_id": "1", + "objects_detected.class_id": 1, + "objects_detected.confidence": 0.6, + "objects_detected.top_left_x": 23, + "objects_detected.top_left_y": 45, + "objects_detected.width": 20, + "objects_detected.height": 30 + }, + { + "inference_id": 2, + "...": "..." + } + ] +} +``` + +You can also specify only a single nested field: + +```json +{ + "selects": [ + { + "property": "inference_id" + }, + { + "property": "objects_detected.class_id" + }, + { + "property": "objects_detected.confidence" + } + ] +} +``` + +The reponse will have 1 object per bounding box. + +```json +{ + "query_result": [ + { + "inference_id": "1", + "objects_detected.class_id": 0, + "objects_detected.confidence": 0.6 + }, + { + "inference_id": "1", + "objects_detected.class_id": 1, + "objects_detected.confidence": 0.6 + }, + { + "inference_id": 2, + "...": "..." + } + ] +} +``` + +```{note} When supplying the bounding box specific fields in filters, group bys, or order bys the columns must also be supplied in the select clause in order for the query to succeed. +``` + +## Inference Search Examples + +### Example 1: Inference ID + +Select all an inference's non-enriched properties where `inference_id` is equal +to `e8cc429c-c4a6-425e-af09-7567fafdb17b` (this is the id that returns when an inference that is sent to Arthur) + +Query Request Body: + +```json +{ + "select": [ + { + "property": "*" + } + ], + "filter": [ + { + "property": "inference_id", + "comparator": "eq", + "value": "e8cc429c-c4a6-425e-af09-7567fafdb17b" + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "inference_id": "e8cc429c-c4a6-425e-af09-7567fafdb17b", + "partner_inference_id": "8734-3423", + "attr1": "something" + } + ] +} +``` + +[back to top](#endpoint-overview) + +### Example 2: Partner Inference ID + +Select all the inference's non-enriched properties where the `partner_inference_id` is equal to `8734-3423` (this is the +id that the user specifies to associate with an inference that is sent to Arthur) + +Query Request Body: + +```json +{ + "select": [ + { + "property": "*" + } + ], + "filter": [ + { + "property": "partner_inference_id", + "comparator": "eq", + "value": "8734-3423" + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "inference_id": "e8cc429c-c4a6-425e-af09-7567fafdb17b", + "partner_inference_id": "8734-3423", + "attr1": "something" + } + ] +} +``` + +[back to top](#endpoint-overview) + +### Example 3: Timestamp Filters + +Select all the inference's non-enriched properties and `anomaly_score` where `inference_timestamp` is greater than or +equal to `2020-22-07T10:00:00` and less than `2020-22-07T11:00:00` + +Query Request Body: + +```json +{ + "select": [ + { + "property": "*" + }, + { + "property": "anomaly_score" + } + ], + "from": "enriched", + "filter": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-07-22T11:00:00Z" + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "inference_id": "0001", + "attr1": "something", + "anomaly_score": 0.34, + "inference_timestamp": "2020-07-22T10:01:23Z" + }, + { + "inference_id": "0002", + "attr1": "something", + "anomaly_score": 0.67, + "inference_timestamp": "2020-07-22T10:02:55Z" + } + ] +} +``` + +[back to top](#endpoint-overview) + +### Example 4: Batch ID Filter + +Select all of the inference's non-enriched properties where `inference_timestamp` is greater than or equal +to `2020-22-07T10:00:00` and less than `2020-22-07T11:00:00` and where `batch_id` is equal to `batch1` + +Query Request Body: + +```json +{ + "select": [ + { + "property": "*" + } + ], + "filter": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-07-22T11:00:00Z" + }, + { + "property": "batch_id", + "comparator": "eq", + "value": "batch1" + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "inference_id": "0001", + "attr1": "something", + "batch_id": "batch1", + "inference_timestamp": "2020-07-22T10:01:23Z" + }, + { + "inference_id": "0002", + "attr1": "something", + "batch_id": "batch1", + "inference_timestamp": "2020-07-22T10:02:55Z" + } + ] +} +``` + +[back to top](#endpoint-overview) + +### Example 5: Aliasing and Order By + +Select the `inference_id`, `state`, `income`, `inference_timestamp`, and `health_score` as `predicted_health_score` +where `inference_timestamp` is greater than or equal to `2020-22-07T10:00:00` and less than `2020-22-07T11:00:00` and +where `state` is equal to `DC` and `income` is greater than or equal to `50000` and less than `90000` + +Query Request Body: + +```json +{ + "select": [ + { + "property": "inference_id" + }, + { + "property": "state" + }, + { + "property": "income" + }, + { + "property": "inference_timestamp" + }, + { + "property": "health_score", + "alias": "predicted_health_score" + } + ], + "filter": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2020-07-22T10:00:00Z" + }, + { + "property": "inference_timestamp", + "comparator": "lt", + "value": "2020-07-22T11:00:00Z" + }, + { + "property": "state", + "comparator": "eq", + "value": "DC" + }, + { + "property": "income", + "comparator": "gte", + "value": 50000 + }, + { + "property": "income", + "comparator": "lt", + "value": 90000 + } + ], + "order_by": [ + { + "property": "income", + "direction": "desc" + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "inference_id": "e8cc429c-c4a6-425e-af09-7567fafdb17b", + "state": "DC", + "income": 75000, + "predicted_health_score": 84.3, + "inference_timestamp": "2020-07-22T10:02:55Z" + }, + { + "inference_id": "1b813f11-94b8-4b5d-b26d-bc1cbc99b708", + "state": "DC", + "income": 52000, + "predicted_health_score": 79.6, + "inference_timestamp": "2020-07-22T10:31:02Z" + } + ] +} +``` + +[back to top](#endpoint-overview) diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/explainability.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/explainability.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e81de60f7c1cedb88a341626e2f93370d89686fa --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/explainability.md.txt @@ -0,0 +1,265 @@ +# Explainability + +## Tabular Explainability + +Returns per datapoint explanations on a model with tabular input data for a specific attribute. For aggregate explainability across datapoints, see {ref}`aggregation_functions_regional_feature_importance` if interested in one property of your model or {ref}`aggregation_functions_regional_feature_importances` if interested in all properties of your model. This is only available if explainability has been {ref}`enabled ` for the model. + +Query Request: +```json +{ + "select": [ + { + "property": "explainer_algo" + }, + { + "property": "explainer_predicted_attribute" + }, + { + "property": "explainer_attribute" + }, + { + "property": "explainer_score" + } + ], + "filter": [ + { + "property": "[inference_id|partner_inference_id]", + "comparator": "eq", + "value": " [string]" + } + ], + "from": "enriched" +} +``` +Query Response: +```json +{ + "query_result": [ + { + "explainer_algo": "[lime|shap]", + "explainer_attribute": " [string]", + "explainer_predicted_attribute": " [string]", + "explainer_score": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "property": "explainer_algo" + }, + { + "property": "explainer_predicted_attribute" + }, + { + "property": "explainer_attribute" + }, + { + "property": "explainer_score" + } + ], + "filter": [ + { + "property": "partner_inference_id", + "comparator": "eq", + "value": "1617235140000" + } + ], + "order_by": [ + { + "property": "explainer_algo", + "direction": "asc" + }, + { + "property": "explainer_predicted_attribute", + "direction": "asc" + }, + { + "property": "explainer_attribute", + "direction": "asc" + } + ], + "from": "enriched" +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "explainer_algo": "lime", + "explainer_attribute": "AGE", + "explainer_predicted_attribute": "prediction_0", + "explainer_score": 0.0016485283063465874 + }, + { + "explainer_algo": "lime", + "explainer_attribute": "BILL_AMT1", + "explainer_predicted_attribute": "prediction_0", + "explainer_score": 0.0032036810960691183 + }, + { + "explainer_algo": "lime", + "explainer_attribute": "BILL_AMT2", + "explainer_predicted_attribute": "prediction_0", + "explainer_score": 0.002008238656596662 + }, + { + "explainer_algo": "lime", + "explainer_attribute": "AGE", + "explainer_predicted_attribute": "prediction_1", + "explainer_score": -0.0016485283063465892 + }, + { + "explainer_algo": "lime", + "explainer_attribute": "BILL_AMT1", + "explainer_predicted_attribute": "prediction_1", + "explainer_score": -0.0032036810960691126 + }, + { + "explainer_algo": "lime", + "explainer_attribute": "BILL_AMT2", + "explainer_predicted_attribute": "prediction_1", + "explainer_score": -0.0020082386565966667 + } + ] +} +``` + +[back to top](#explainability) + + +## NLP Explainability +The `nlp_explanation` function can be used to query and filter explanations for tokens in NLP inferences. In using this function the user can filter and order tokens by importance. The following are available optional properties: + * `nlp_explanation.token` - References a token within a specific inference. + * `nlp_explanation.location` - References a token's absolute location within a specific inference. + * `nlp_explanation.value` - References a token's explanation value within a specific inference. + +Query Request: +```json +{ + "select": [ + { + "function": "nlp_explanation", + "alias": " [Optional]", + "parameters": { + "attribute_name": " [string]", + "nlp_predicted_attribute": " [string]", + "nlp_explainer": "[lime|shap]" + } + } + ], + "filter": [ + { + "property": "nlp_explanation.token", + "comparator": "eq", + "value": "" + }, + { + "property": "nlp_explanation.location", + "comparator": "eq", + "value": "" + } + ], + "order_by": [ + { + "property": "nlp_explanation.value", + "direction": "desc" + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "inference_id": " [string]", + "nlp_explanation": [ + { + "algorithm": "[lime|shap]", + "predicted_attribute_name": " [string]", + "importance_scores": [ + { + "attribute_name": " [string]", + "tokens": [ + { + "token": " [string]", + "position": " [int]", + "value": " [float]" + } + ] + } + ] + } + ] + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "nlp_explanation", + "parameters": { + "attribute_name": "transcription", + "nlp_predicted_attribute": "cardiovascular__pulmonary", + "nlp_explainer": "lime" + } + } + ], + "filter": [ + { + "property": "partner_inference_id", + "comparator": "eq", + "value": "1617321572000" + }, + { + "property": "nlp_explanation.token", + "comparator": "eq", + "value": "dog" + } + ] +} +``` + +Sample Response: +```json +{ + "query_result": [ + { + "inference_id": "0b40e801-6f04-47aa-94d7-99b5f86a6bc4", + "nlp_explanation": { + "algorithm": "lime", + "predicted_attribute_name": "cardiovascular__pulmonary", + "importance_scores": [ + { + "attribute_name": "", + "tokens": [ + { + "token": "postoperative", + "position": 10, + "explanation_value": 0.007326229429931506 + }, + { + "token": "postoperative", + "position": 24, + "explanation_value": 0.002047999807176794 + } + ] + } + ] + } + } + ] +} +``` +[back to top](#explainability) diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/grouped_inference_queries.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/grouped_inference_queries.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3bb0cd2b9d714fe76f1162b4cf43724f980bc5ae --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/grouped_inference_queries.md.txt @@ -0,0 +1,352 @@ +# Advanced Example: Unique Identifiers + +Initial analyses that treat inferences as independent of one another can provide tremendous value. But over time, +models often make multiple predictions about the same real-world entities. No matter what you're predicting, +it can be helpful to compare the inputs and outputs of your model on an entity-by-entity basis. + +For example, let's say that your model makes predictions about whether customers will make a purchase in the next 30 +days. You might have the following attributes: +- `customer_id`: a non-input attribute +- `will_purchase_pred`: the prediction attribute: whether a customer will make a purchase in the next 30 days +- `will_purchase_gt`: the ground truth attribute: whether a customer actually did make a purchase within 30 days +- `recent_purchase_count`: an input attribute with the total number of purchases the customer made in the last 90 days +- `newsletter_subscriber`: an input attribute depicting whether the customer subscribes to the deals newsletter + +Your model might be run on the full universe of Customer IDs at some regular interval. With Arthur's powerful Query +API, you can follow inferences for each Customer ID through time and answer questions like: +- How does `recent_purchase_count` tend to change for each customer, from the first to last time inference is conducted? +- What is the per-customer variance of `recent_purchase_count` across time? +- How many customers changed their newsletter subscription status, from one month ago to today? +- What is the distribution of the lifetimes of Customer IDs? + +## Example Queries + +We'll walk through some example queries for these entity-by-entity comparisons, exploring the sample case outlined +above. + +### Per-Customer Variance +We can look at how consistent `recent_purchase_count` is _for each customer_ across time. We'll compute the variance in +`recent_purchase_count` for each customer across all their inferences, and then roll those individual variances up into +a distribution. + +```json +{ + "select": [ + { + "function": "distribution", + "alias": "recent_purchase_count_variance_distribution", + "parameters": { + "property": { + "nested_function": { + "function": "variance", + "parameters": { + "property": "recent_purchase_count" + } + } + }, + "num_bins": 20 + } + } + ], + "subquery": { + "select": [ + { + "property": "recent_purchase_count" + }, + { + "property": "customer_id" + } + ], + "group_by": [ + { + "property": "customer_id" + } + ] + } +} +``` + +### Change Across Batches +If our model is a batch model, we might want to compare the values for each customer between two difference batches. +We'll again look at the distribution of change in the `recent_purchase_count`, but this time look at the difference for +each customer between two specific batches. + +```json +{ + "select": [ + { + "function": "distribution", + "alias": "recent_purchase_count_difference_distribution", + "parameters": { + "property": { + "nested_function": { + "function": "subtract", + "parameters": { + "left": "batch1_recent_purchase_count", + "right": "batch2_recent_purchase_count" + } + } + }, + "num_bins": 20 + } + } + ], + "subquery": { + "select": [ + { + "property": "customer_id" + }, + { + "property": "batch1_recent_purchase_count" + }, + { + "property": "batch2_recent_purchase_count" + } + ], + "subquery": { + "select": [ + { + "property": "customer_id" + }, + { + "function": "anyIf", + "parameters": { + "result": "recent_purchase_count", + "property": "batch_id", + "comparator": "eq", + "value": "batch1" + }, + "alias": "batch1_recent_purchase_count" + }, + { + "function": "anyIf", + "parameters": { + "result": "recent_purchase_count", + "property": "batch_id", + "comparator": "eq", + "value": "batch2" + }, + "alias": "batch2_recent_purchase_count" + } + ], + "group_by": [ + { + "property": "customer_id" + } + ] + }, + "where": [ + { + "property": "batch1_recent_purchase_count", + "comparator": "NotNull" + }, + { + "property": "batch2_recent_purchase_count", + "comparator": "NotNull" + } + ] + } +} +``` + +### Change Across First to Last Inference Per Customer +We can again compare the difference between two absolute points, but instead of comparing fixed batches compute it for +the earliest and latest inference for each customer: + +```json +{ + "select": [ + { + "function": "distribution", + "alias": "recent_purchase_count_difference_distribution", + "parameters": { + "property": { + "nested_function": { + "function": "subtract", + "parameters": { + "left": "newest_recent_purchase_count", + "right": "oldest_recent_purchase_count" + } + } + }, + "num_bins": 20 + } + } + ], + "subquery": { + "select": [ + { + "property": "customer_id" + }, + { + "function": "argMax", + "parameters": { + "argument": "inference_timestamp", + "value": "recent_purchase_count" + }, + "alias": "newest_recent_purchase_count" + }, + { + "function": "argMin", + "parameters": { + "argument": "inference_timestamp", + "value": "recent_purchase_count" + }, + "alias": "oldest_recent_purchase_count" + } + ], + "group_by": [ + { + "property": "customer_id" + } + ] + } +} +``` + +### Change in Categorical Variables +We can also look at change in categorical variables on an entity-by-entity basis. Let's look at the distribution of +customers who remained subscribed, remained unsubscribed, newly subscribed, or newly unsubscribed from one batch to the +next. + +```json +{ + "select": [ + { + "alias": "batch1_not_subscribed", + "function": "equals", + "parameters": { + "left": "batch1_newsletter_subscriber", + "right": 0 + } + }, + { + "alias": "batch1_is_subscribed", + "function": "equals", + "parameters": { + "left": "batch1_newsletter_subscriber", + "right": 1 + } + }, + { + "alias": "batch2_not_subscribed", + "function": "equals", + "parameters": { + "left": "batch2_newsletter_subscriber", + "right": 0 + } + }, + { + "alias": "batch2_is_subscribed", + "function": "equals", + "parameters": { + "left": "batch2_newsletter_subscriber", + "right": 1 + } + }, + { + "alias": "stayed_unsubscribed_count", + "function": "and", + "parameters": { + "left": { + "alias_ref": "batch1_not_subscribed" + }, + "right": { + "alias_ref": "batch2_not_subscribed" + } + } + }, + { + "alias": "did_subscribe_count", + "function": "and", + "parameters": { + "left": { + "alias_ref": "batch1_not_subscribed" + }, + "right": { + "alias_ref": "batch2_is_subscribed" + } + } + }, + { + "alias": "stayed_subscribed_count", + "function": "and", + "parameters": { + "left": { + "alias_ref": "batch1_is_subscribed" + }, + "right": { + "alias_ref": "batch2_is_subscribed" + } + } + }, + { + "alias": "did_unsubscribe_count", + "function": "and", + "parameters": { + "left": { + "alias_ref": "batch1_is_subscribed" + }, + "right": { + "alias_ref": "batch2_not_subscribed" + } + } + } + ], + "subquery": { + "select": [ + { + "property": "customer_id" + }, + { + "property": "batch1_newsletter_subscriber" + }, + { + "property": "batch2_newsletter_subscriber" + } + ], + "subquery": { + "select": [ + { + "property": "customer_id" + }, + { + "function": "anyIf", + "parameters": { + "result": "newsletter_subscriber", + "property": "batch_id", + "comparator": "eq", + "value": "batch1" + }, + "alias": "batch1_newsletter_subscriber" + }, + { + "function": "anyIf", + "parameters": { + "result": "newsletter_subscriber", + "property": "batch_id", + "comparator": "eq", + "value": "batch2" + }, + "alias": "batch2_newsletter_subscriber" + } + ], + "group_by": [ + { + "property": "customer_id" + } + ] + }, + "where": [ + { + "property": "batch1_newsletter_subscriber", + "comparator": "NotNull" + }, + { + "property": "batch2_newsletter_subscriber", + "comparator": "NotNull" + } + ] + } +} +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/index.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a9d160a827f8a18c7683b621177e0431365fec6e --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/index.md.txt @@ -0,0 +1,63 @@ +# API Query Guide + + +This selection of guides and references covers the basics of querying data using the Arthur Query API Endpoints. +The complete reference for the full Arthur API documentation can be found +[here](https://docs.arthur.ai/api-documentation/v3-api-docs.html), +and the reference to the Query Endpoint can be found +[here](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/query). + +## {doc}`Query Quickstart ` +For beginners to the Arthur Query API, see the {doc}`query_quickstart` +for a basic walkthrough on querying data about your model's performance. + +## References: + +### {doc}`Endpoint Overview ` +The {doc}`endpoint_overview` covers the structure and parameters of queries +and provides more examples to get started. + +### {doc}`Model Evaluation Functions ` +This reference shows the basic metrics needed to evaluate the performance of models (accuracy, confusion matrix, MSE, etc) + +### {doc}`Data Drift ` +This reference shows querying data drift over time, +which is needed to diagnose which changes in data could explain a change in model performance. + +### {doc}`Explainability ` +This reference shows how to query explanations for inferences. Whether in terms of features in tabular models, +words in NLP models, or regions of pixels in CV models, explainability offers a rough approximation of +the _how_ and _why_ behind a model's inferences. + +### {doc}`Aggregation Functions ` +This reference shows how to apply aggregators like an _average_ (`avg`) or a _maximum_ (`max`) to a query. + +### {doc}`Transformation Functions ` +This reference shows the transformations available within an Arthur query (numerical operations, binning variables, +grouping by time resolution, etc) + +### {doc}`Composing Functions ` +This reference shows composing functions to fit complex transformations into a single query + +### {doc}`Subqueries ` +This reference shows how to embed queries within queries. + +## {doc}`Grouped Inference Queries ` +This guide shows how to query information pertaining to individual instances of data over time. + +```{toctree} +:maxdepth: 2 +:hidden: + +Query Quickstart +Endpoint Overview +Model Evaluation Functions +Data Drift +Explainability +Aggregation +Transformations +Composition +Subqueries +Advanced Example: Unique Identifiers + +``` diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/model_evaluation_functions.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/model_evaluation_functions.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..9ea8cb8d57c1ff376acd3f51c4b4222de7df98d1 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/model_evaluation_functions.md.txt @@ -0,0 +1,974 @@ +# Model Evaluation Functions + +## Regression +All regression evaluation metrics will follow the below request body structure. + +Query Request: +```json +{ + "select": [ + { + "function": "[rmse|mae|rSquared]", + "alias": " [optional string]", + "parameters": { + "ground_truth_property": " [string]", + "predicted_property": " [string]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +### RMSE +Get the RMSE between a prediction attribute and a ground truth attribute. + +Sample Request: +```json +{ + "select": [ + { + "function": "rmse", + "alias": "error", + "parameters": { + "ground_truth_property": "FICO_actual", + "predicted_property": "FICO_predicted" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "error": 0.76 + } + ] +} +``` +[back to top](#model-evaluation-functions) + +### MAE +Get the Mean Absolute Error between a prediction attribute and a ground truth attribute. +This function takes an optional parameter `aggregation` that allows swapping the aggregation from `"avg"` +to either `"min"` or `"max"`. This can be helpful if you're looking for extremes, as in the lowest or highest absolute error, respectively. +Additionally, this functions supports optional params `normalizationMax` and `normalizationMin` +that accept numbers and will perform min/max normalization on the values before aggregation if both params are provided. + +Query Request: +```json +{ + "select": [ + { + "function": "mae", + "alias": " [optional string]", + "parameters": { + "predicted_property": " [string]", + "ground_truth_property": " [string]", + "aggregation": "[avg|min|max] (default avg, optional)", + "normalizationMin": " [optional number]", + "normalizationMax": " [optional number]" + } + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "mae", + "alias": "error", + "parameters": { + "ground_truth_property": "FICO_actual", + "predicted_property": "FICO_predicted" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "error": 0.76 + } + ] +} +``` +[back to top](#model-evaluation-functions) + + +### R Squared +Get the R Squared value between a prediction attribute and a ground truth attribute. + +Sample Request: +```json +{ + "select": [ + { + "function": "rSquared", + "alias": "rsq", + "parameters": { + "ground_truth_property": "FICO_actual", + "predicted_property": "FICO_predicted" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "rsq": 0.94 + } + ] +} +``` +[back to top](#model-evaluation-functions) + +## Binary Classification +When using any binary classification evaluation functions with a multiclass model, outputs will be calculated assuming a one vs. all approach. + +### Confusion Matrix +Calculates the confusion matrix for a classification model. For binary classifiers, users must specify a probability `threshold` to count a prediction as a positive class. + +Query Request: +```json +{ + "select": [ + { + "function": "confusionMatrix", + "alias": " [optional string]", + "parameters": { + "threshold": " [required only for binary classifiers]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": { + "true_positive": " [int]", + "false_positive": " [int]", + "true_negative": " [int]", + "false_negative": " [int]" + } + } + ] +} +``` + +Sample Request: Calculate the confusion matrix for a binary classifier with a threshold of 0.5 (standard threshold for confusion matrix). +```json +{ + "select": [ + { + "function": "confusionMatrix", + "parameters": { + "threshold": 0.5 + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "confusionMatrix": { + "true_positive": 100480, + "false_positive": 100076, + "true_negative": 100302, + "false_negative": 99142 + } + } + ] +} +``` +[back to top](#model-evaluation-functions) + + +### Confusion Matrix Rate +Calculates the confusion matrix rates for a classification model. For binary classifiers, users must specify a probability `threshold` to count a prediction as a positive class. + +Query Request: +```json +{ + "select": [ + { + "function": "confusionMatrixRate", + "alias": " [optional string]", + "parameters": { + "threshold": " [required only for binary classifiers]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": { + "true_positive_rate": " [float]", + "false_positive_rate": " [float]", + "true_negative_rate": " [float]", + "false_negative_rate": " [float]", + "accuracy_rate": " [float]" + } + } + ] +} +``` + + +Sample Request: Calculate the confusion matrix for a binary classifier with a threshold of 0.5 (standard threshold for confusion matrix). +```json +{ + "select": [ + { + "function": "confusionMatrixRate", + "parameters": { + "threshold": 0.5 + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "confusionMatrixRate": { + "true_positive_rate": 0.5033513340213003, + "false_positive_rate": 0.49943606583557076, + "true_negative_rate": 0.5005639341644292, + "false_negative_rate": 0.4966486659786997 + } + } + ] +} +``` + +[back to top](#model-evaluation-functions) + + +### Confusion Matrix Variants + +If you only want a specific metric derived from a confusion matrix, you can use one of the following functions: +* `truePositiveRate` +* `falsePositiveRate` +* `trueNegativeRate` +* `falseNegativeRate` +* `accuracyRate` +* `balancedAccuracyRate` +* `f1` +* `sensitivity` +* `specificity` +* `precision` +* `recall` + +For example, to return the `truePositiveRate`: +```json +{ + "select": [ + { + "function": "truePositiveRate", + "parameters": { + "threshold": 0.5, + "ground_truth_property":"class_a", + "predicted_property":"ground_truth_a" + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "truePositiveRate": 0.5033513340213003 + } + ] +} +``` + +[back to top](#model-evaluation-functions) + +### AUC + +The [Area Under the ROC Curve](https://en.wikipedia.org/wiki/Receiver_operating_characteristic#Area_under_the_curve) +can also be computed for binary classifiers. + +Sample Query: +```json +{ + "select": [ + { + "function": "auc", + "parameters": { + "ground_truth_property":"class_a", + "predicted_property":"ground_truth_a" + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "auc": 0.9192331426352897 + } + ] +} +``` + +## Multiclass Classification + +### Multiclass Accuracy Rate +Calculates the global accuracy rate. + +Query Request: +```json +{ + "select": [ + { + "function": "accuracyRateMulticlass", + "alias": " [optional string]" + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "accuracyRateMulticlass": " [float]" + } + ] +} +``` + + +Example: +```json +{ + "select": [ + { + "function": "accuracyRateMulticlass" + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "accuracyRateMulticlass": 0.785 + } + ] +} +``` +[back to top](#model-evaluation-functions) + +### Multiclass Confusion Matrix +Calculates the confusion matrix for a multiclass model with regard to a single class. The predicted attribute and ground truth attribute must be passed as parameters. + +Query Request: +```json +{ + "select": [ + { + "function": "confusionMatrixMulticlass", + "alias": " [optional string]", + "parameters": { + "predicted_property": "", + "ground_truth_property": "" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": { + "true_positive": " [int]", + "false_positive": " [int]", + "true_negative": " [int]", + "false_negative": " [int]" + } + } + ] +} +``` + +Example: +```json +{ + "select": [ + { + "function": "confusionMatrixMulticlass", + "parameters": { + "predicted_property": "predicted_class_A", + "ground_truth_property": "gt_predicted_class_A" + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "confusionMatrix": { + "true_positive": 100480, + "false_positive": 100076, + "true_negative": 100302, + "false_negative": 99142 + } + } + ] +} +``` +[back to top](#model-evaluation-functions) + + +### Multiclass Confusion Matrix Rate +Calculates the confusion matrix rates for a multiclass classification model in regards to a single predicted class. + +Query Request: +```json +{ + "select": [ + { + "function": "confusionMatrixRateMulticlass", + "alias": " [optional string]", + "parameters": { + "predicted_property": "predicted_class_A", + "ground_truth_property": "gt_predicted_class_A" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": { + "true_positive_rate": " [float]", + "false_positive_rate": " [float]", + "true_negative_rate": " [float]", + "false_negative_rate": " [float]", + "accuracy_rate": " [float]", + "balanced_accuracy_rate": " [float]", + "precision": " [float]", + "f1": " [float]" + } + } + ] +} +``` + +Example calculating the confusion matrix rates: +```json +{ + "select": [ + { + "function": "confusionMatrixRateMulticlass", + "parameters": { + "predicted_property": "predicted_class_A", + "ground_truth_property": "gt_predicted_class_A" + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "confusionMatrixRateMulticlass": { + "true_positive_rate": 0.6831683168316832, + "false_positive_rate": 0.015653220951234198, + "true_negative_rate": 0.9843467790487658, + "false_negative_rate": 0.31683168316831684, + "accuracy_rate": 0.9378818737270875, + "balanced_accuracy_rate": 0.8337575479402245, + "precision": 0.8884120171673819, + "f1": 0.7723880597014925 + } + } + ] +} +``` +[back to top](#model-evaluation-functions) + + +If you only want a specific value from the confusion matrix rate function, you can use one of the following functions: +* `truePositiveRateMulticlass` +* `falsePositiveRateMulticlass` +* `trueNegativeRateMulticlass` +* `falseNegativeRateMulticlass` + +For example, to return the `truePositiveRate`: +```json +{ + "select": [ + { + "function": "truePositiveRateMulticlass", + "parameters": { + "predicted_property": "predicted_class_A", + "ground_truth_property": "gt_predicted_class_A" + } + } + ] +} +``` +Response: +```json +{ + "query_result": [ + { + "truePositiveRate": 0.5033513340213003 + } + ] +} +``` +[back to top](#model-evaluation-functions) + +### Multiclass F1 +Calculates the components needed to compute a F1 score for a multiclass model. + +In this example, the model has 3 classes: `class-1`, `class-2`, `class-3` and +the corresponding ground truth labels `class-1-gt`, `class-2-gt`, `class-3-gt`. + +Query Request: +```json +{ + "select": [ + { + "function": "count", + "alias": "count" + }, + { + "function": "confusionMatrixRateMulticlass", + "alias": "class-1", + "parameters": { + "predicted_property": "class-1", + "ground_truth_property": "class-1-gt" + } + }, + { + "function": "countIf", + "alias": "class-1-gt", + "parameters": { + "property": "multiclass_model_ground_truth_class", + "comparator": "eq", + "value": "class-1-gt" + }, + "stage": "GROUND_TRUTH" + }, + { + "function": "confusionMatrixRateMulticlass", + "alias": "class-2", + "parameters": { + "predicted_property": "class-2", + "ground_truth_property": "class-2-gt" + } + }, + { + "function": "countIf", + "alias": "class-2-gt", + "parameters": { + "property": "multiclass_model_ground_truth_class", + "comparator": "eq", + "value": "class-2-gt" + }, + "stage": "GROUND_TRUTH" + }, + { + "function": "confusionMatrixRateMulticlass", + "alias": "class-3", + "parameters": { + "predicted_property": "class-3", + "ground_truth_property": "class-3-gt" + } + }, + { + "function": "countIf", + "alias": "class-3-gt", + "parameters": { + "property": "multiclass_model_ground_truth_class", + "comparator": "eq", + "value": "class-3-gt" + }, + "stage": "GROUND_TRUTH" + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "count": 7044794, + "class-1-gt": 2540963, + "class-2-gt": 2263918, + "class-3-gt": 2239913, + "class-1": { + "true_positive_rate": 0.4318807475748368, + "false_positive_rate": 0.3060401245073361, + "true_negative_rate": 0.6939598754926639, + "false_negative_rate": 0.5681192524251633, + "accuracy_rate": 0.5994314383074935, + "balanced_accuracy_rate": 0.5629203115337503, + "precision": 0.4432575070302042, + "f1": 0.437495178612114 + }, + "class-2": { + "true_positive_rate": 0.42177322676881407, + "false_positive_rate": 0.3514795196528837, + "true_negative_rate": 0.6485204803471163, + "false_negative_rate": 0.578226773231186, + "accuracy_rate": 0.5756528863725469, + "balanced_accuracy_rate": 0.5351468535579652, + "precision": 0.3623427088234848, + "f1": 0.38980575845890253 + }, + "class-3": { + "true_positive_rate": 0.26144274353512836, + "false_positive_rate": 0.2805894672521546, + "true_negative_rate": 0.7194105327478454, + "false_negative_rate": 0.7385572564648716, + "accuracy_rate": 0.5737983254017079, + "balanced_accuracy_rate": 0.4904266381414869, + "precision": 0.3028268576818381, + "f1": 0.2806172238153916 + } + } + ] +} +``` + +With this result, you can calculate the [weighted F1 score](https://towardsdatascience.com/multi-class-metrics-made-simple-part-ii-the-f1-score-ebe8b2c2ca1) +by multiplying each classes's F1 score by the count of the ground truth and dividing by the total count. +In this example, that would be +``` +(class-1.f1 * class-1-gt + class-2.f1 * class-2-gt + class-3.f1 * class-3-gt) / count +``` +and with numbers: +``` +(0.437495178612114 * 2540963 + + 0.38980575845890253 * 2263918 + + 0.2806172238153916 * 2239913) / 7044794 + += 0.3722898785 +``` + +[back to top](#model-evaluation-functions) + +## Object Detection + +### Objects Detected +For multiclass, multilabel, and regression models, querying model performance works the same for Arthur computer vision models as more tabular and NLP models. But `Object Detection` computer vision have some special fields you can use when querying. + +Example query fetching all bounding box fields: + +```json +{ + "selects": [ + { + "property": "inference_id" + }, + { + "property": "objects_detected" + } + ] +} +``` + +The reponse will have 1 object per bounding box. + +```json +{ + "query_result": [ + { + "inference_id": "1", + "objects_detected.class_id": 0, + "objects_detected.confidence": 0.6, + "objects_detected.top_left_x": 23, + "objects_detected.top_left_y": 45, + "objects_detected.width": 20, + "objects_detected.height": 30 + }, + { + "inference_id": "1", + "objects_detected.class_id": 1, + "objects_detected.confidence": 0.6, + "objects_detected.top_left_x": 23, + "objects_detected.top_left_y": 45, + "objects_detected.width": 20, + "objects_detected.height": 30 + }, + {"inference_id": 2, + "...": "..."} + ] +} +``` + +You can also specify only a single nested field: + +```json +{ + "selects": [ + { + "property": "inference_id" + }, + { + "property": "objects_detected.class_id" + }, + { + "property": "objects_detected.confidence" + } + ] +} +``` + +The reponse will have 1 object per bounding box. + +```json +{ + "query_result": [ + { + "inference_id": "1", + "objects_detected.class_id": 0, + "objects_detected.confidence": 0.6 + }, + { + "inference_id": "1", + "objects_detected.class_id": 1, + "objects_detected.confidence": 0.6 + }, + {"inference_id": 2, + "...": "..."} + ] +} +``` + +```{note} When supplying the bounding box specific fields in filters, group bys, or order bys the columns must also be supplied in the select clause in order for the query to succeed. +``` + +### Mean Average Precision + +Calculates Mean Average Precision for an object detection model. This is used as measure of accuracy for object detection models. + +`threshold` determines minimum IoU value to be considered a match for a label. `predicted_property` and `ground_truth_property` are optional parameters and should be the names of the predicted and ground truth attributes for the model. They default to `"objects_detected"` and `"label"` respectively if nothing is specified for these parameters. + +Query Request: + +```json +{ + "select": [ + { + "function": "meanAveragePrecision", + "alias": " [Optional]", + "parameters": { + "threshold": " [float]", + "predicted_property": " [str]", + "ground_truth_property": " [str]" + } + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Example: + +```json +{ + "select": [ + { + "function": "meanAveragePrecision", + "parameters": { + "threshold": 0.5, + "predicted_property": "objects_detected", + "ground_truth_property": "label" + } + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "meanAveragePrecision": 0.78 + } + ] +} +``` + +## Bias + +### Bias Mitigation + +Calculates mitigated predictions based on conditional thresholds, returning 0/1 for each inference. +```{note} This function returns null for inferences that don't match any of the provided conditions. +``` +Query Request: + +```json +{ + "select": + [ + { + "function": "biasMitigatedPredictions", + "alias": " [Optional]", + "parameters": + { + "predicted_property": " [str]", + "thresholds": + [ + { + "conditions": + { + "property": " [string or nested]", + "comparator": " [string] Optional: default 'eq'", + "value": "" + }, + "threshold": " [float]" + } + ] + } + } + ] +} +``` + +Query Response: + +```json +{ + "query_result": [ + { + "": " [int]" + } + ] +} +``` + +Example: + +```json +{ + "select": + [ + { + "function": "biasMitigatedPredictions", + "parameters": + { + "predicted_property": "prediction_1", + "thresholds": + [ + { + "conditions": + [ + { + "property": "SEX", + "value": 1 + } + ], + "threshold": 0.4 + }, + { + "conditions": + [ + { + "property": "SEX", + "value": 2 + } + ], + "threshold": 0.6 + } + ] + } + } + ] +} +``` + +Response: +```json +{ + "query_result": + [ + { + "SEX": 1, + "biasMitigatedPredictions": 1 + }, + { + "SEX": 2, + "biasMitigatedPredictions": 0 + }, + { + "SEX": 1, + "biasMitigatedPredictions": 0 + } + ] +} +``` + +[back to top](#model-evaluation-functions) + diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/query_quickstart.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/query_quickstart.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d824342e8b90fd39ea95be78c920c23766484a32 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/query_quickstart.md.txt @@ -0,0 +1,369 @@ +# Query Quickstart + +To access information about a model's performance, drift, bias, or other enabled enrichments, write a `query` object +and submit it with the Arthur SDK using `arthur_model.query(query)` + +For a general overview of this endpoint, including a more thorough descriptions of its rules, power, and customizability, +see the {doc}`endpoint_overview` page. + +In each of the following examples, let our model be a binary classifier, and let `GT1` and `PRED1` be the names of our model's grouth truth attribute and predicted value, respectively. + +## Accuracy +This is usually the simplest way to check for classifier performance. We can fetch a model's accuracy rate by querying a `select` on the function `accuracyRate` using the typical threshold `0.5`. + +Given the following query: +```python +GT1 = 'gt_isFraud' +PRED1 = 'pred_isFraud' + +query = { + "select": [ + { + "function": "accuracyRate", + "parameters": + { + "threshold" : 0.5, + "ground_truth_property" : GT1, + "predicted_property" : PRED1 + } + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'accuracyRate': 0.999026947368421}] +``` + +## Accuracy by batch +To expand the accuracy query by batch, add the `batch_id` property to the query's `select`, and add a `group_by` to the query using `batch_id`. + +Given the following query: +```python +GT1 = 'gt_isFraud' +PRED1 = 'pred_isFraud' + +query = { + "select": [ + { + "function": "accuracyRate", + "parameters": + { + "threshold" : 0.5, + "ground_truth_property" : GT1, + "predicted_property" : PRED1 + } + }, + { + "property": "batch_id" + } + ], + "group_by": [ + { + "property": "batch_id" + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'accuracyRate': 0.999704, 'batch_id': 'newbatch3'}, + {'accuracyRate': 0.999744, 'batch_id': 'newbatch0'}, + {'accuracyRate': 0.992952, 'batch_id': 'newbatch19'}, + {'accuracyRate': 0.999616, 'batch_id': 'newbatch5'}, + {'accuracyRate': 0.999144, 'batch_id': 'newbatch6'}, + ...] +``` + +## Batch IDs +Querying accuracy by batch includes the `batch_id` values in the query result. But to query the `batch_id`s on their own, only `select` and `group_by` the `batch_id`. + +Given the following query: +```python +query = { + "select": [ + { + "property": "batch_id" + } + ], + "group_by": [ + { + "property": "batch_id" + } + ] +} + +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'batch_id': 'newbatch19'}, + {'batch_id': 'newbatch18'}, + {'batch_id': 'newbatch13'}, + {'batch_id': 'newbatch12'}, + {'batch_id': 'newbatch16'}, +...] +``` + +## Accuracy (single batch) +To query the accuracy for only one batch, add a `filter` to the query according to the rule `batch_id == BATCHNAME` + +Given the following query (for a specified batch name): +```python +GT1 = 'gt_isFraud' +PRED1 = 'pred_isFraud' +BATCHNAME = "newbatch19" + +query = { + "select": [ + { + "function": "accuracyRate", + "parameters": + { + "threshold" : 0.5, + "ground_truth_property" : GT1, + "predicted_property" : PRED1 + } + }, + { + "property": "batch_id" + } + ], + "group_by": [ + { + "property": "batch_id" + } + ], + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": BATCHNAME + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'accuracyRate': 0.992952, 'batch_id': 'newbatch19'}] +``` + +## Confusion Matrix +A confusion matrix counts the number of true positive, true negative, false positive, and false negative classifications; knowing these values is usually more useful than just accuracy when it is time to improve your model. + +To query a confusion matrix, we use the `confusionMatrix` function in our query's `select`. + +```{note} For the confusionMatrix function, the ground_truth_property and predicted_property parameters are optional. +``` + +Given the following query: +```python +query = { + "select": [ + { + "function": "confusionMatrix", + "parameters": + { + "threshold" : 0.5 + } + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'confusionMatrix': + {'false_negative': 4622, + 'false_positive': 0, + 'true_negative': 4745195, + 'true_positive': 183}}] +``` + +## Confusion Matrix (single batch) +As we did with accuracy, to get a confusion matrix for a single batch we add the property `batch_id` to the query's `select`, add a `group_by` using `batch_id`, and then add a `filter` according to the rule `batch_id == BATCHNAME` + +Given the following query (for a specified batch name): +```python +BATCHNAME = 'newbatch19' + +query = { + "select": [ + { + "function": "confusionMatrix", + "parameters": + { + "threshold" : 0.5 + } + }, + { + "property": "batch_id" + } + ], + "group_by": [ + { + "property": "batch_id" + } + ], + "filter": [ + { + "property": "batch_id", + "comparator": "eq", + "value": BATCHNAME + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'batch_id': 'newbatch19', + 'confusionMatrix': + {'false_negative': 1762, + 'false_positive': 0, + 'true_negative': 248238, + 'true_positive': 0}}] +``` + +## Confusion Matrix (by group) +Instead of querying for metrics and grouping by batch, we can group by other groupings as well. Here, we use the model's non-input attribute `race` so that we can compare model performance across different demographics. To do this, we add the group name `race` to our query's `select` and to its `group_by` + +Given the following query: +```python +GROUP = 'race' + +query = { + "select": [ + { + "function": "confusionMatrix", + "parameters": { + "threshold" : 0.5 + } + }, + { + "property": GROUP + } + ], + "group_by": [ + { + "property": GROUP + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'confusionMatrix': {'false_negative': 1162, + 'false_positive': 0, + 'true_negative': 1184707, + 'true_positive': 44}, + 'race': 'hispanic'}, + {'confusionMatrix': {'false_negative': 1145, + 'false_positive': 0, + 'true_negative': 1186659, + 'true_positive': 49}, + 'race': 'asian'}, + {'confusionMatrix': {'false_negative': 1137, + 'false_positive': 0, + 'true_negative': 1187500, + 'true_positive': 38}, + 'race': 'black'}, + {'confusionMatrix': {'false_negative': 1178, + 'false_positive': 0, + 'true_negative': 1186329, + 'true_positive': 52}, + 'race': 'white'}] +``` + +## Predictions +Here we aren't querying any metrics - we are just accessing all the predictions that have output by the model. + +Given the following query: +```python +PRED1 = 'pred_isFraud' +query = { + "select": [ + { + "property": PRED1 + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'pred_isFraud_1': 0.005990342859493804}, + {'pred_isFraud_1': 0.02271116879043313}, + {'pred_isFraud_1': 0.15305224676085477}, + {'pred_isFraud_1': 0}, + {'pred_isFraud_1': 0.03280797449330532}, +...] +``` + +## Predictions (average) +To _only_ query the average value across all these predictions (since querying all predictions and then averaging locally can be slow for production-sized query results), we only need to add the `avg` function to our query's `select`, with our predicted value `PRED1` now being a parameter of `avg` instead of a property we directly select. + +Given the following query: +```python +PRED1 = 'pred_isFraud' +query = { + "select": [ + { + "function": "avg", + "parameters": { + "property": PRED1 + } + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'avg': 0.016030786000398464}] +``` + +## Predictions (average over time) +To get the average predictions on each day, we add the function `roundTimestamp` to our select using a `time_interval` of `day` - this groups the timestamp information according to `day` instead of options like `hour` or `week`. Then, we add a `group_by` to the query using the `alias` (`DAY`) specified in the `roundTimestamp` function. + +Given the following query: +```python +PRED1 = 'pred_isFraud' +query = { + "select": [ + { + "function": "avg", + "parameters": { + "property": PRED1 + } + }, + { + "function": "roundTimestamp", + "alias": "DAY", + "parameters": { + "property": "inference_timestamp", + "time_interval": "day" + } + } + ], + "group_by": [ + { + "alias": "DAY" + } + ] +} +query_result = arthur_model.query(query) +``` +The `query_result` will be: +```python +[{'avg': 0.016030786000359423, 'DAY': '2022-07-11T00:00:00Z'}, + {'avg': 0.018723459201003300, 'DAY': '2022-07-12T00:00:00Z'}, + {'avg': 0.014009919280009284, 'DAY': '2022-07-13T00:00:00Z'}, + {'avg': 0.016663649020394829, 'DAY': '2022-07-14T00:00:00Z'}, + {'avg': 0.017791902929210039, 'DAY': '2022-07-15T00:00:00Z'}, + ...] +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/subqueries.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/subqueries.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3a53d7afd553242b53425b28fe03ee0d4acca9ea --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/subqueries.md.txt @@ -0,0 +1,130 @@ +# Subqueries + +For a general overview of this endpoint, see the {doc}`endpoint_overview` page. + +Subqueries are a powerful feature of modern SQL. The query endpoint +can support subqueries via the `"subquery"` field in the request body. +The format of `"subquery"` is exactly the same as the full request body +and can even support recursive subqueries! Here are some helpful examples +that show how to use them. + +## Concise queries with subqueries +Sometimes you may have a calculation that needs to be aggregated in multiple ways. +One option would be to repeat the calculation in each aggregation's +`select`, but that can lead to lots of repeated JSON. Subqueries can be +used to reduce duplicated expressions. In this example, we use a subquery +to square the property `Home_Value`, then aggregate with `min`, `max`, and `avg` +without repeating the calculation. + +```json +{ + "select": [ + { + "function": "max", + "alias": "max", + "parameters": { + "property": { + "alias_ref": "hv_squared" + } + } + }, + { + "function": "min", + "alias": "min", + "parameters": { + "property": { + "alias_ref": "hv_squared" + } + } + }, + { + "function": "avg", + "alias": "avg", + "parameters": { + "property": { + "alias_ref": "hv_squared" + } + } + } + ], + "subquery": { + "select": [ + { + "function": "multiply", + "alias": "hv_squared", + "parameters": { + "left": "Home_Value", + "right": "Home_Value" + } + } + ] + } +} +``` + +This example returns: +```json +{ + "query_result": [ + { + "avg": 33413668226.974968, + "max": 17640000000000, + "min": 0 + } + ] +} +``` + +## Subqueries for grouping +Subqueries can also be used to perform operations on grouped data. +In this example, we get the count of the inferences in each batch +in the subquery, then average those counts. +```json +{ + "select": [ + { + "function": "avg", + "alias": "avg_count", + "parameters": { + "property": { + "alias_ref": "batch_count" + } + } + }, + { + "function": "count", + "alias": "total_batches" + } + ], + "subquery": { + "select": [ + { + "function": "count", + "alias": "batch_count" + }, + { + "property": "batch_id" + } + ], + "group_by": [ + { + "property": "batch_id" + } + ] + } +} +``` + +This query returns: +```json +{ + "query_result": [ + { + "avg_count": 5930.2558139534885, + "total_batches": 86 + } + ] +} +``` + + diff --git a/files/arthur-docs-markdown/user-guide/api-query-guide/transformation_functions.md.txt b/files/arthur-docs-markdown/user-guide/api-query-guide/transformation_functions.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..e31d4b32ee4499e5b04ec5024584f7e30dcc2db3 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/api-query-guide/transformation_functions.md.txt @@ -0,0 +1,678 @@ +# Transformation Functions + +For transformation functions, it will be helpful to include `property` in the request to help associate the transformation function values, for example: + +```json +{ + "select": [ + { + "property": " [string]" + }, + { + "function": "roundTimestamp", + "alias": " [optional string]", + "parameters": { + "property": " [string]", + "time_interval": "[second|minute|hour|day|month|year]" + } + } + ] +} +``` + +We omit `property` for brevity in the following examples. + +For an explanation of nested functions, see the guide {doc}`composing_functions`. + +### Round Timestamp +Rounds a timestamp property to the provided time interval. This function requires one property +which must be an attribute of type datetime and one parameter, `time_interval`. + +Query Request: +```json +{ + "select": [ + { + "function": "roundTimestamp", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "time_interval": "[second|minute|hour|day|month|year]" + } + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [string]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "roundTimestamp", + "parameters": { + "property": "inference_timestamp", + "time_interval": "day" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "roundTimestamp": "2020-08-10T00:00:00.000Z" + }, + { + "roundTimestamp": "2020-08-09T00:00:00.000Z" + }, + { + "roundTimestamp": "2020-08-08T00:00:00.000Z" + } + ] +} +``` +[back to top](#transformation-functions) + +### Label By Max Column +Given a list of columns, returns a string column with the name of the column containing the max value for the row. For example, this function can be used to extract the max probability from a vector of probability properties. + +Query Request: +```json +{ + "select": [ + { + "function": "labelByMaxColumn", + "alias": " [optional string]", + "parameters": { + "properties": [ + " [string]" + ] + } + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [string]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "labelByMaxColumn", + "alias": "classPrediction", + "parameters": { + "properties": [ + "class_1", + "class_2", + "class_3" + ] + } + } + ] +} +``` +Sample Response: +```json +{ + "classPrediction": [ + { + "classPrediction": "class_1" + }, + { + "classPrediction": "class_1" + }, + { + "classPrediction": "class_2" + } + ] +} +``` +[back to top](#transformation-functions) + +### Bin Continuous +This function bins a continuous value based on supplied thresholds. The bins will be formed as: +`[< threshold_1, threshold_1 <= x < threshold_2, ... , threshold_(n-1) <= x < threshold_(n), threshold_(n) < x]`. +The response bins will be labeled with an integer id corresponding to the ordered bin, starting at 1. +If `n` thresholds are given, `n+1` bins will be returned. + +Query Request: +```json +{ + "select": [ + { + "function": "binContinuous", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "bin_thresholds": [ + " [number]", + " [number]", + " [number]" + ] + } + } + ] +} +``` + +Query Response: +```json +{ + "query_result": [ + { + "": " [int]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "property": "age" + }, + { + "function": "binContinuous", + "alias": "ageBin", + "parameters": { + "property": "age", + "bin_thresholds": [ + 18, + 65, + 95 + ] + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "age": 10, + "ageBin": 1 + }, + { + "age": 20, + "ageBin": 2 + }, + { + "age": 70, + "ageBin": 3 + } + ] +} +``` +[back to top](#transformation-functions) +### Bins To Quantiles +Returns an array of values representing the quantiles based on the number of bins passed to the function. +For example if you supply `"num_bins": "10"`, then this query will return the value in your data at the +10%, 20%, ... , 90%, 100% quantiles. + +Query Request: +```json +{ + "select": [ + { + "function": "binsToQuantiles", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]", + "num_bins": " [int]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": [ + "float" + ] + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "binsToQuantiles", + "alias": "quantiles", + "parameters": { + "property": "age", + "num_bins": 10 + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "": [ + 19, + 28, + 37, + 46, + 55, + 64, + 73, + 82, + 91 + ] + } + ] +} +``` +[back to top](#transformation-functions) + +### Date Diff +Returns the difference of two timestamps in `unit`s. Valid units are: +`second`, `minute`, `hour`, `day`, `week`, `month`, `quarter`, and `year`. + +Query Request: +```json +{ + "select": [ + { + "function": "dateDiff", + "alias": " [optional string]", + "parameters": { + "unit": "[second|minute|hour|day|week|month|quarter|year]", + "start_date": " [string or nested]", + "end_date": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": "difference [int]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "dateDiff", + "alias": "date_diff", + "parameters": { + "unit": "second", + "start_date": "inference_timestamp", + "end_date": "prev_timestamp" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "date_diff": 100 + } + ] +} +``` +[back to top](#transformation-functions) + + +### Neighbor +Returns the value of the column `offset` rows next to this row in the ordering. +`default` is the value that is returned when the offset goes out of bounds on the row set. +It is recommended to use this function in a subquery with an `order_by` clause to get consistent ordering. + +Query Request: +```json +{ + "select": [ + { + "function": "neighbor", + "alias": " [optional string]", + "parameters": { + "offset": " [int]", + "property": " [string or nested]", + "default": " [any]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": "neighbor_value [any]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "neighbor", + "alias": "prev_timestamp", + "parameters": { + "property": "inference_timestamp", + "offset": -1, + "default": null + } + } + ], + "order_by": [ + { + "property": "inference_timestamp", + "direction": "desc" + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "prev_timestamp": "2021-06-15T00:00:00.000Z" + } + ] +} +``` +[back to top](#transformation-functions) + + +### Arithmetic +`add`, `subtract`, `multiply`, and `divide` are valid arithmetic functions. +Each takes two columns as input and returns the result of the arithmetic expression. + +Query Request: +```json +{ + "select": [ + { + "function": "[add|subtract|multiply|divide]", + "alias": " [optional string]", + "parameters": { + "left": " [string or nested]", + "right": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": "expression_result [number]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "multiply", + "alias": "double_home_value", + "parameters": { + "left": "Home_Value", + "right": 2 + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "double_home_value": 20000 + } + ] +} +``` + +Sample nested request to compute `(Home_Value + Car_Value) * 2` +```json +{ + "select": [ + { + "function": "multiply", + "alias": "double_loans", + "parameters": { + "left": { + "nested_function": { + "function": "add", + "alias": "total_loan", + "parameters": { + "left": "Home_Value", + "right": "Car_Value" + } + } + }, + "right": 2 + } + } + ] +} +``` +Sample Nested Response: +```json +{ + "query_result": [ + { + "double_loans": 20000 + } + ] +} +``` +[back to top](#transformation-functions) + + +### Absolute Value +Take the absolute value of a property. + +Query Request: +```json +{ + "select": [ + { + "function": "abs", + "alias": " [optional string]", + "parameters": { + "property": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": " [float]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "abs", + "alias": "abs_delta", + "parameters": { + "property": "delta" + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "abs_delta": 55.45 + } + ] +} +``` +[back to top](#transformation-functions) + +### Logical Functions +`equals`, `and`, and `or` are valid logical functions. Each takes two columns as input and returns the result of the logical expression. These follow the same API as [Arithmetic Functions](#arithmetic) + +Query Request: +```json +{ + "select": [ + { + "function": "[equals|and|or]", + "alias": " [optional string]", + "parameters": { + "left": " [string or nested]", + "right": " [string or nested]" + } + } + ] +} +``` +Query Response: +```json +{ + "query_result": [ + { + "": "expression_result [0 or 1]" + } + ] +} +``` + +Sample Request: +```json +{ + "select": [ + { + "function": "equals", + "alias": "has_phd", + "parameters": { + "left": "education", + "right": 4 + } + } + ] +} +``` +Sample Response: +```json +{ + "query_result": [ + { + "has_phd": 1 + } + ] +} +``` + +Sample nested request to compute `has_phd` or `has_masters` +```json +{ + "select": [ + { + "function": "or", + "alias": "has_higher_education", + "parameters": { + "left": { + "nested_function": { + "function": "equals", + "alias": "has_phd", + "parameters": { + "left": "education", + "right": 4 + } + } + }, + "right": { + "nested_function": { + "function": "equals", + "alias": "has_masters", + "parameters": { + "left": "education", + "right": 3 + } + } + } + } + } + ] +} +``` +Sample Nested Response: +```json +{ + "query_result": [ + { + "has_higher_education": 1 + } + ] +} +``` +[back to top](#transformation-functions) \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/arthur_quickstart.md.txt b/files/arthur-docs-markdown/user-guide/arthur_quickstart.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..1117802a984557672b294f5f7ffd00cfcf7c9a97 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/arthur_quickstart.md.txt @@ -0,0 +1,145 @@ +# Arthur Quickstart + +From a Python environment with the `arthurai` package installed, this quickstart code will: +1. Make binary classification predictions on a small dataset +2. Onboard the model with reference data to Arthur +3. Log batches of model inference data with Arthur +4. Get performance results for our model + +## Imports + +The `arthurai` package can be `pip`-installed from the terminal, along with `numpy` and `pandas`: +`pip install arthurai numpy pandas`. + +Then you can import from the `arthurai` package like this: +```python +# Arthur imports +from arthurai import ArthurAI +from arthurai.common.constants import InputType, OutputType, Stage + +# other libraries used in this example +import numpy as np +import pandas as pd +``` + +## Model Predictions + +We write out samples from a Titanic survival prediction dataset explicitly in python, +giving the age of each passenger, the cost of their ticket, the passenger class of their ticket, +and the ground-truth label of whether they survived. +Our model's outputs are given by a predict function using only the `age` variable. We split the data into + +* `reference_data` for onboarding the model +* `inference_data` for in-production inferences the model processes + +```{note} +We include model outputs, ground-truth values, and non-input data in reference_data, which are optional but recommended. +``` + +```python +# Define Titanic sample data +titanic_data = pd.DataFrame({ + 'age': [16.0, 24.0, 19.0, 58.0, 30.0, 22.0, 40.0, 37.0, 65.0, 32.0], + 'fare': [86.5, 49.5042, 8.05, 153.4625, 7.8958, 7.75, 7.8958, 29.7, 7.75, 7.8958], + 'passenger_class': [1, 1, 3, 1, 3, 3, 3, 1, 3, 3], + 'survived': [1, 1, 1, 1, 0, 1, 0, 0, 0, 0]}) + +# Split into reference and inference data +reference_data, inference_data = titanic_data[:6], titanic_data[6:] + +# Predict the probability of Titanic survival as inverse percentile of age +def predict(age): + nearest_age_index = np.argmin(np.abs(np.sort(reference_data['age']) - age)) + return 1 - (nearest_age_index / (len(reference_data) - 1)) + +# reference_data and inference_data contain the model's inputs and outputs +reference_data['pred_survived'] = reference_data['age'].apply(predict) +inference_data['pred_survived'] = inference_data['age'].apply(predict) +``` + +## Onboarding + +This code will only run once you enter a valid username and password. + +We register our `arthur_model` with Arthur as a tabular classifier with the name "TitanicQuickstart". +Then we build its model schema from `reference_data`, specifying which attributes are in which {ref}`stage `. +Additionally, we configure extra settings for the `passenger_class` attribute. Then we save the model to the platform. + +```python +# Connect to Arthur +arthur = ArthurAI(url="https://app.arthur.ai", + login="") + +# Register the model type with Arthur +arthur_model = arthur.model(partner_model_id="TitanicQuickstart", + input_type=InputType.Tabular, + output_type=OutputType.Multiclass) + +# Map PredictedValue attribute to its corresponding GroundTruth attribute value. +# This tells Arthur that the `pred_survived` column represents +# the probability that the ground truth column has the value 1 +pred_to_ground_truth_map = {'pred_survived' : 1} + +# Build arthur_model schema on the reference dataset, +# specifying which attribute represents ground truth +# and which attributes are NonInputData. +# Arthur will monitor NonInputData attributes even though they are not model inputs. +arthur_model.build(reference_data, + ground_truth_column='survived', + pred_to_ground_truth_map=pred_to_ground_truth_map, + non_input_columns=['fare', 'passenger_class']) + +# Configure the `passenger_class` attribute +# 1. Turn on bias monitoring for the attribute. +# 2. Specify that the passenger_class attribute has possible values [1, 2, 3], +# since that information was not present in reference_data (only values 1 and 3 are present). +arthur_model.get_attribute(name='passenger_class').set(monitor_for_bias=True, + categories=[1,2,3]) +# onboard the model to Arthur +arthur_model.save() +``` + + +## Sending Inferences + +Here we send batches of inferences from `inference_data` to Arthur. + +```python +# send four batches of inferences +for batch in range(4): + # Sample the inference dataset with predictions + inferences = inference_data.sample(np.random.randint(2, 5)) + + # Send the inferences to Arthur + arthur_model.send_inferences(inferences, batch_id=f"batch_{batch}") +``` + +## Performance Results +With our model onboarded and inferences sent, we can get performance results from Arthur. View your model in your +Arthur dashboard, or use the code below to fetch the overall accuracy rate: + +```python +# query model accuracy across the batches +query = { + "select": [ + { + "function": "accuracyRate" + } + ] +} +query_result = arthur_model.query(query) +``` + +If you print `query_result`, you should see `[{'accuracyRate': 1}]`. + +## Next Steps + +### {doc}`Basic Concepts ` + +The {doc}`basic_concepts` page contains a quick introduction to important terms and ideas to get familiar with +model monitoring using the Arthur platform. + +### {doc}`Onboard Your Model ` + +The {doc}`Model Onboarding walkthrough ` page covers the steps of onboarding a model, formatting attribute +data, and sending inferences to Arthur. diff --git a/files/arthur-docs-markdown/user-guide/basic_concepts.md.txt b/files/arthur-docs-markdown/user-guide/basic_concepts.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..9a01f482e38374541fc6d7f5d398fc0bf0771ae9 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/basic_concepts.md.txt @@ -0,0 +1,197 @@ +# Basic Concepts + +## Arthur Overview + +The Arthur platform monitors, measures, and improves machine learning models to deliver better business outcomes. +Arthur helps data scientists, product owners, and business leaders accelerate model operations and optimize for +accuracy, explainability, and fairness. + +To use Arthur, you: + +1. Register your model with the Arthur system +2. Set reference data for baseline analytics +3. Send inference data over time + +With this data, Arthur quantifies and centralizes your models' performance for efficient querying and automated +analytics. + +## Models and Onboarding + +### Registering a Model + +When you register a model with Arthur, you define the way the model processes data. +Arthur is model-agnostic and platform-agnostic, so no matter which tools you used to build or deploy, +you can use Arthur to log all the data your model receives and produces - +registration tells Arthur how this will happen. + +(basic_concepts_input_output_types)= +#### Input and Output Types +These are the data types that define the data that enters and exits your model. +The `InputType` of a model specifies whether data enters your model as a tabular dataframe, as an image, or as raw text. +The `OutputType` of a model specifies the modeling task at hand: +whether your model is predicting values for a regression task, predicting probabilities for a classification task, +or predicting bounding boxes for a computer vision object-detection task. + +(basic_concepts_streaming_vs_batch)= +#### Streaming vs. Batch + +When registering a model, you specify whether your model ingests data either as a stream or in batches. +A streaming model receives instances of data as they come into the deployed model. A batch model, in contrast, +receives data in groups, and is often preferred if your model runs as a job rather than operating in realtime or over +a data stream. + +Indicating a batch model simply means that you'll supply an additional "batch_id" to group your inferences, and Arthur +will default to measuring performance for each batch rather than by the inference timestamps. + +(basic_concepts_attributes_and_stages)= +### Attributes and Stages + +Attributes are analagous to the different columns that make up your model's data. +Each attribute has a value type: these can be standard types like `int` and `str`, +or datatypes for complex models like raw text and images. + +When you are onboarding a model, Arthur categorizes each attribute into a different `Stage`, +depending on the role of the attribute in the model pipeline: + +1. `ModelPipelineInput`: these attributes are the features your model receives as input +1. `PredictedValue`: these attributes are the output values your model produces +1. `GroundTruth`: these attributes are the true values for your model's prediction task, for comparing the model's +outputs against for performance metrics +1. `NonInputData`: these attributes are the additional metadata you can log with Arthur +related to input data that your model doesn't take as an input feature, +e.g. protected attributes like age, race, or sex, or specific business data like a unique customer ID + +### Model Schema + +The model schema is a record of important properties of your model's attributes, including their value type and `Stage`. + +As you log data over time with Arthur, the model schema is used to type-check ingested data. +This prevents analytics from being skewed by scenarios +like `int` values suddenly replacing `float` values causing silent bugs. + +Arthur also records attribute properties in the model schema, +like the range of possible values an attribute has in your data. +These properties are used to get a sense of your data's high-level structure, +_not_ to enforce that future attributes have strictly these same properties. + +(basic_concepts_reference_dataset)= +### Reference Dataset + +```{image} /_static/images/Model-Reference-Dataset-Light-Mode.png +:align: center +:class: only-light +``` + +```{image} /_static/images/Model-Reference-Dataset-Dark-Mode.png +:align: center +:class: only-dark +``` + +The reference dataset is a representative sample of the input features your model ingests. +This can be the model's training data, +or any other set of data that captures the distribution of data your model's inputs are sourced from. + +This dataset is used to compute baseline model analytics. +By capturing the distribution of data you expect your model to receive, +Arthur can detect, surface, and diagnose data drift before it impacts results. +Note that Arthur can compute data drift metrics against any two distributions you choose (e.g. inferences +now compared to the same time last year), but the platform uses the reference dataset as the default. + +The only required stage to be included in the reference dataset is `ModelPipelineInput`. +But we also recommend including data from the `PredictedValue`, `GroundTruth`, and `NonInputData` stages so that +Arthur can measure drift in those attributes over time as well. + +## Sending Data to Arthur + +### Inferences + +The data your model produces over time is logged in the Arthur platform as **inferences**. +These inferences contain attributes from the `ModelPipelineInput` and `PredictedValue` stage (model inputs and outputs), +from which Arthur computes performance metrics. In addition, when you log these inferences, +you have the option to include `GroundTruth` and `NonInputData` attributes. + +### Sending Ground Truth Separately + +```{image} /_static/images/Ground-Truth-Light-Mode.png +:align: center +:class: only-light +``` + +```{image} /_static/images/Ground-Truth-Dark-Mode.png +:align: center +:class: only-dark +``` + +`GroundTruth` attributes are often not available when models produce inferences. +Therefore, Arthur allows you to send this attribute data to the platform _after_ sending the original inferences, +using an ID to pair data with the right inference. + +## Metrics + +Metrics are the measurements Arthur computes to quantify model performance. +Default metrics are the basic model performance metrics generated automatically by Arthur, +e.g. accuracy, mean-squared error, or AUC. +Furthermore, additional metrics can be written using the API and added to a model for +measuring performance specific to a custom business use-case. + +You can use the Arthur API to efficiently query model performance metrics at scale. +Model metrics can be accessed in the online Arthur UI, using the Arthur API, and by using the Arthur Python SDK. + + +See the {doc}`/user-guide/api-query-guide/index` for more resources on model metrics. + +## Alerts + +An alert is a message notifying you that something has occurred with your model. +With alerts, Arthur makes it easy to provide a continuous view into your model +by highlighting important changes in model performance. + +An alert is triggered based on an **_alert rule_**, which you define using a metric and a threshold: +when the metric crosses your threshold, the alert is activated. +This alert can then be delivered to you via email, highlighted in the online Arthur UI, +and/or accessed via integrations such as PagerDuty and Slack. + +For an in-depth guide to setting alerts, see the {doc}`/user-guide/walkthroughs/metrics_alerts` guide. + +## Enrichments + +Enrichments are additional services that the Arthur platform provides for state-of-the-art proactive model monitoring: + +- **Explainability**: +methods for computing the importance of individual features from your data on your model's outcomes. +- **Anomaly Detection**: drift metrics for quantifying how far incoming inferences have drifted +from the distribution of your model's reference dataset. +- **Hotspots**: automated identification of segments of your data where your model is underperforming. +- **Bias Mitigation**: +methods for model post-processing that improve the fairness of outcomes without re-deploying your model. + +Once activated, these enrichments are computed on Arthur's backend automatically, +with results viewable in the online UI dashboard and queryable from Arthur's API. + +The {doc}`/user-guide/walkthroughs/enrichments` guide shows how to set up enrichments and describes all of Arthur's currently offered enrichments. + +## Insights + +Insights are proactive notifications about your model's performance. For example, once you've enabled the Hotspots +enrichment you'll receive insights about regions of your data space where model accuracy has significantly degraded. + +## Model Groups and Versioning + +Arthur helps you track the improvements of model updates with Model Versioning. + +If a change has occurred to your data preprocessing pipeline, if you have retrained your model, +or if you've reset your model's reference data, your updated model is likely +a new version of a previous model addressing the same task. In this case, Arthur recommends +keeping these models within the same Model Group to track performance as you continue improving your model. + +Each model you onboard to Arthur is placed in a Model Group. As you change the model over time, +you can add new versions of the model that will live in the same group. +Tracking improvement in performance over time within a Model Group is then +streamlined for quick insights in the Arthur UI dashboard. + +## Next Steps + +### {doc}`Onboard Your Model ` + +The {doc}`Model Onboarding walkthrough ` covers the steps of onboarding +a model, formatting attribute data, and sending inferences to Arthur. diff --git a/files/arthur-docs-markdown/user-guide/index.md.txt b/files/arthur-docs-markdown/user-guide/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..4f6cd5e31ec6507445a9e855259f354726e45cb1 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/index.md.txt @@ -0,0 +1,38 @@ +# Arthur User Guide + +## {doc}`Basic Concepts ` +For beginners to Arthur, see our {doc}`basic_concepts` page for an introduction to Arthur and how +Arthur's services support monitoring machine learning models. + +## {doc}`Arthur Quickstart ` +The {doc}`arthur_quickstart` has ready-to-go code to create your first Arthur model. + +## {doc}`Walkthroughs ` +The {doc}`walkthroughs ` are detailed guides that cover onboarding complex models, +setting up model alerts, and using Arthur enrichments to gain extra insights on model performance. + +### {doc}`Model Onboarding ` +The {doc}`Model Onboarding walkthrough ` is a good choice to start +with: it covers everything you need to get your existing model integrated with Arthur. + +## {doc}`API Query Guide ` +The {doc}`api-query-guide/index` shows how to use the Arthur API, a query engine that can request the +information you need about your model's performance - efficiently and at scale. + +## {doc}`Integrations ` +Arthur offers {doc}`integrations ` with other services to make it easy for users to add Arthur to their +stack. + + +```{toctree} +:hidden: +:maxdepth: 2 + +Basic Concepts +Arthur Quickstart +Walkthroughs +API Query Guide +Integrations +``` + + \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/integrations/alert.md.txt b/files/arthur-docs-markdown/user-guide/integrations/alert.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..ffc67974f2c38ea5e1b1fa45e98c3f1c8bc0ea63 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/integrations/alert.md.txt @@ -0,0 +1,71 @@ +(alert_integration)= +# PagerDuty & ServiceNow Integrations + +This guide walks through integrating Arthur alerting with your incident response tools to streamline your model monitoring operations. + +(pagerduty_integration)= +## PagerDuty Integration Guide + +With the Arthur + PagerDuty integration you can notify on-call teams in PagerDuty of alerts triggered by Arthur. In order to set up this integration, follow these steps: + +### Step 1: Set up your email integration in PagerDuty + +There are 3 ways to configure an email integration in PagerDuty. Please follow one of the 3 options in the [PagerDuty Email Integration Guide](https://www.pagerduty.com/docs/guides/email-integration-guide/ "PagerDuty Email Integration Guide") to retrieve your integration email address. + + +### Step 2: Configure your integration in Arthur + +To configure the PagerDuty integration for a model in Arthur, you can send a POST request to `/alert_notification_configurations`. + +* `model_id` - UUID of the model this alert notification configuration belongs to. +* `type` - Type of notification to send. In this case, `"PagerDuty"`. +* `destination` - The integration email address obtained in Step 1. +* `enabled` - Whether or not the notification configuration is enabled. Defaults to true. + +Example Query Request: +```json +{ + "model_id" : " [string]", + "type" : "[PagerDuty]", + "destination" : " [string]", +} +``` + +For more information on configuring alert notifications, please see {ref}`Alert Notification Configuration Guide `. + +### Step 3: Start monitoring! + +Your integration is now read to use! When an alert is triggered in Arthur for this model, an incident will be created in your PagerDuty. For more information on what data will be included in an alert notification sent to PagerDuty please see {ref}`What is included in an Alert Notification? `. + +(servicenow_integration)= +## ServiceNow Integration Guide + +With the Arthur + ServiceNow integration you can set up email automations to notify on-call teams in ServiceNow of alerts triggered by Arthur. In order to set up this integration, follow these steps: + +### Step 1: Set up your email integration in ServiceNow + +An inbound email action in ServiceNow can be configured to receive Arthur alerts and create incidents in response to those alerts. Please see the [ServiceNow Email Actions Guide](https://docs.servicenow.com/bundle/rome-servicenow-platform/page/administer/notification/concept/c_InboundEmailActions.html "ServiceNow Inbound Email Actions Guide") for details on how to do this. Once you have set-up an email action to handle incoming Arthur alerts and generate incidents from those alerts, retrieve the ServiceNow instance email address for Step 2. + +### Step 2: Configure your integration in Arthur + +To configure the ServiceNow integration for a model in Arthur, you can send a POST request to `/alert_notification_configurations`. + +* `model_id` - UUID of the model this alert notification configuration belongs to. +* `type` - Type of notification to send. In this case, `"ServiceNow"`. +* `destination` - The integration email address obtained in Step 1. +* `enabled` - Whether or not the notification configuration is enabled. Defaults to true. + +Example Query Request: +```json +{ + "model_id" : " [string]", + "type" : "[ServiceNow]", + "destination" : " [string]", +} +``` + +For more information on alert notifications, please see {ref}`Alert Notification Configuration Guide `. + +### Step 3: Start monitoring! + +Your integration is now read to use! When an alert is triggered in Arthur for this model, an incident will be created in your ServiceNow instance. For more information on what data will be included in an alert notification sent to ServiceNow please see {ref}`What is included in an Alert Notification? `. diff --git a/files/arthur-docs-markdown/user-guide/integrations/index.md.txt b/files/arthur-docs-markdown/user-guide/integrations/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2a5056abcb44b62812ebd8254ed5cbea725f2a3b --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/integrations/index.md.txt @@ -0,0 +1,20 @@ +# Integrations + +This collection of guides outlines various integrations between Arthur and 3rd party services, frameworks, and platforms. Ranging from model onboarding examples to pipeline setups for automatically ingesting new inferences, these tutorials will help you quickly bring Arthur into your team's ML development lifecycle. + +## {doc}`SparkML Integration ` +This guide provides an example of integrating with the ArthurAI platform to monitor a SparkML model. + +## {doc}`AWS SageMaker Data Capture Integration ` +This guide walks through setting up a Sagemaker integration to send Data Capture log files to Arthur. + +## {doc}`PagerDuty & ServiceNow ` +This guide walks through integrating Arthur alerting with your incident response tools to streamline your model monitoring operations. + +```{toctree} +:maxdepth: 2 +:hidden: +SparkML Integration +AWS SageMaker Data Capture Integration +PagerDuty & ServiceNow +``` diff --git a/files/arthur-docs-markdown/user-guide/integrations/sagemaker.md.txt b/files/arthur-docs-markdown/user-guide/integrations/sagemaker.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..db82a918e287adba14f3f72907e41d5bfafa813b --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/integrations/sagemaker.md.txt @@ -0,0 +1,262 @@ +(sagemaker_integration)= +## AWS SageMaker Data Capture Integration + +Models deployed with AWS SageMaker can be configured to automatically push their real-time inferences to the Arthur platform by utilizing [SageMaker Data Capture](https://docs.aws.amazon.com/sagemaker/latest/dg/model-monitor-data-capture.html). This guide walks through setting up that integration and utilizing a Lambda function to send Data Capture log files to be ingested by the Arthur platform. + +### Prerequisites + +- The model for which inferences are being ingested has already been onboarded onto Arthur. +- The SageMaker model schema matches that of its Arthur model counterpart. + +### SageMaker Configuration + +AWS SageMaker offers two features that enable this Arthur integration: Real-time endpoints & Data Capture. Endpoints are APIs that expose a trained model. Users can use the API to retrieve predictions from the hosted model in the endpoint. Data Capture is a feature that logs the inputs and outputs of each prediction from the hosted model endpoints. + +To enable Data Capture in a way that accurately logs all input and output data needed for the Arthur integration, a configuration must be passed in when deploying an endpoint (see below). + +#### Configuring Data Capture through the SageMaker SDK + +An extended description of the following configuration can be found in the "SageMaker Python SDK" tab of the [SageMaker Data Capture documentation](https://docs.aws.amazon.com/sagemaker/latest/dg/model-monitor-data-capture.html#model-monitor-data-capture-defing.title). + +```python +from sagemaker.model import Model +from sagemaker.model_monitor import DataCaptureConfig + +s3_capture_upload_path = f"s3://{bucket-name}/{model-specific-path}/datacapture" + +model = Model( ... ) + +data_capture_config = DataCaptureConfig( + enable_capture=True, + sampling_percentage=100, + destination_s3_uri=s3_capture_upload_path, + capture_options=['REQUEST','RESPONSE'], +) + +model.deploy( + data_capture_config=data_capture_config, + ... +) +``` + +This integration requires that `DataCaptureConfig` be set such that: +- `capture_options` includes both `REQUEST` and `RESPONSE` to record model inputs and outputs for each inference +- `sampling_percentage` is set to `100` in order to comprehensively ingest all new inferences +- `enable_capture` is set to `True` + +#### Configuring Data Capture through the SageMaker API + +To create a real-time endpoint via the API, users can also call the [CreateEndpoint](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpoint.html) API. In order to ensure that this endpoint is deployed with Data Capture enabled, it must receive an `EndpointConfigName` that matches an `EndpointConfig` created using the [CreateEndpointConfig](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateEndpointConfig.html) API with the following specifications: +``` +{ + ..., + "DataCaptureConfig": { + "CaptureContentTypeHeader": { + "CsvContentTypes": [ "string" ], + "JsonContentTypes": [ "string" ] + }, + "CaptureOptions": [ + { + "CaptureMode": "Input" + }, + { + "CaptureMode": "Output" + } + ], + "DestinationS3Uri": "string", + "EnableCapture": true, + "InitialSamplingPercentage": 100, + "KmsKeyId": "string" + }, + "EndpointConfigName": "string", + ... +} +``` +This integration requires that `DataCaptureConfig` be set such that: +- `CaptureContentTypeHeader` be specified to an Arthur-supported content type (see section below). If no CsvContentTypes or JsonContentTypes are specified, SageMaker will by default `base64` encode when capturing the data. This content type is currently not supported by the Arthur platform. +- `CaptureOptions` be set to both the `Input` and `Output` Capture Modes. +- `EnableCapture` be set to `true`. +- `InitialSamplingPercentage` be set to `100`. + +#### Supported Data Formats + +AWS SageMaker algorithms can accept and produce numerous MIME types for the HTTP payloads used in retrieving predictions from endpoint-hosted models. The MIME type utilized in an endpoint invocation also corresponds to the format of the Data Captured inference. + +The Arthur platform supports the following MIME types / data formats for those types: + +##### MIME Type: `text/csv` +``` +37,Self-emp-not-inc,227253,Preschool,1,Married-civ-spouse,Sales,Husband,White,Male,0,0,30,Mexico\n24,Private,211129,Bachelors,13,Never-married,Exec-managerial,Other-relative,White,Female,0,0,60,United-States\n +``` +- Each inference is represented as an ordered row of comma separate values, where each value represents a feature in the inference + - These features must be specified in the same order as their counterparts in the corresponding Arthur Model +- If multiple inferences are included in a single call to `invoke_endpoint`, each inference is separated by `\n` + +##### MIME Type: `application/json` +Arthur currently supports two unique JSON formats, which are described with examples below. + +###### Option 1: Column-Ordered List of Feature-Values +```json +{ + "instances": [ + { + "features": [1.5, 16, "testStringA", false] + }, + { + "features": [2.0, 12, "testStringB", true] + } + ] +} +``` +- Each inference is represented as a new object inside a JSON array + - The upper level key mapping to this inference array is named one of the following: `instances`, `predictions` +- Each object within this JSON array is a key mapping to an ordered array of features + - The second level key mapping to this feature array is named one of the following: `features`, `probabilities` + +###### Option 2: Feature-Name Keys to Values Map +```json +{ + "predictions": [ + { + "closest_cluster": 5, + "distance_to_cluster": 36.5 + }, + { + "closest_cluster": 2, + "distance_to_cluster": 90.3 + } + ] +} +``` +- Each inference is represented as an object inside a JSON array + - The upper level key mapping to this inference array is named one of the following: `instances`, `predictions` +- Each object within this JSON array has keys representing feature names mapping to their corresponding feature values + - The names of these features cannot be any one of the following: `instances`, `predictions`, `features`, `probabilities` + +#### Specifying Partner Inference ID on Arthur-Ingested Data Capture Inferences + +The Arthur platform enforces that each uploaded inference has a Partner Inference ID, which is a unique identifier used as the matching mechanism for joining ground truth data. Arthur's SageMaker integration populates the Arthur Inference ID from two possible sources in SageMaker. The default is to use SageMaker's EventID, which is a random ID auto-generated by SageMaker for each request. SageMaker's EventID is captured in the `eventMetadata/eventId` field of the data capture output files. As another option, SageMaker allows Invoke-Endpoint API callees to specify an `InferenceId` (or `inference-id`) to a call when using the API, SDK function, or CLI to invoke an endpoint. When InferenceId is specified, SageMaker appends an `eventMetadata/inferenceId` field to the Data Capture event. Both approaches generate a single `eventId` or `inferenceId` for each call to Invoke-Endpoint. If an InferenceId is specified, Arthur will use it as the Arthur Partner Inference ID. Otherwise it will default to the SageMaker EventId. + +One tricky part about SageMaker's Invoke-Endpoint API it it allows requesting multiple inferences in a single Invoke-Endpoint API call. In this case, the SageMaker EventId or callee-specified InferenceId would be shared by all inferences in the call and would not be unique. When this occurs, the Arthur integration will append an index number to either the EventId or InferenceId based on the order of the inference in the call to Invoke-Endpoint. + +When ingesting Data Capture inferences from SageMaker, the following table describes the partner inference ID any given inference is assigned on the Arthur platform. + + + + + + + + + + + + + + + + + +
SageMaker Invoke CallWithout Inference ID provided in Invoke EndpointWith Inference ID provided in Invoke Endpoint
Single Inference in Invoke EndpointEventIdInferenceId
Multiple Inferences in Invoke EndpointEventId_{index_within_invoke_endpoint_call}InferenceId_{index_within_invoke_endpoint_call}
+ +- `InferenceId` and `EventId` refer to the Inference ID and Event ID, respectively, provided when calling Invoke Endpoint either through the [API](https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_runtime_InvokeEndpoint.html) or [boto3 SDK](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/sagemaker-runtime.html#SageMakerRuntime.Client.invoke_endpoint). +- `index_within_invoke_endpoint_call` refers to the index of the specific inference within a group of multiple/mini-batch inferences sent through the Invoke-Endpoint call. +- For example, for an Invoke-Endpoint call including CSV data `1,2,3,4\n5,6,7,8\n` and Inference ID `abcdefg-12345`, the inference containing the features `1,2,3,4` would have a partner inference ID of `abcdefg-12345_0` on the Arthur platform and the inference containing the features `5,6,7,8` would have a partner inference ID of `abcdefg-12345_1`. + +(s3_batch_ingestion)= +### AWS Lambda Setup + +This section provides an example of a single-Lambda-per-Arthur-model setup. The following code is meant to serve as an example and can be implemented in a variety of ways that fit your organization's tech stack. + +This build sets up an S3 object creation Lambda trigger to run the function whenever SageMaker writes a file to the bucket. This sample code will then pull the file and upload it to Arthur. In its current form, the code assumes that all S3 object notifications will be for the single model for the configured `ARTHUR_MODEL_ID`. See the following sections for the configurations required to use the lambda. + +#### Lambda Function Configurations + +To create the Lambda function, go to the AWS Lambda Console, click "Create function" and select "Use a Blueprint", then search for and select `s3-get-object-python`. + +Then ensure you select or create an Execution Role with access to your Data Capture upload bucket(s). + +Finally, ensure the following configurations are set and create the function: +- Timeout: 15 min 0 sec (must be set after Lambda function creation in the "Configuration" / "General configuration" tab) +- Environment Variables + - `ARTHUR_HOST`: The host URL for your Arthur deployment (or [https://app.arthur.ai/](https://app.arthur.ai/) for SaaS customers) + - `ARTHUR_MODEL_ID`: The ID assigned to the Arthur model to accept the new inferences + - `ARTHUR_ACCESS_TOKEN`: An access token for the Arthur platform + - This can be replaced by the retrieval of this token at Lambda runtime + - The token must, at the very least, provide `raw_data` write access + +#### Lambda Function Trigger + +- **Source**: `S3` +- **Bucket**: Your Data Capture configured S3 bucket +- **Event**: `All object create events` +- **Prefix**: Path to your model's specific Data Capture output directory +- **Suffix**: `.jsonl` + +##### AWS S3 Trigger Overlap Error ##### + +AWS prevents multiple S3 triggers from applying to the same subset(s) of files. Therefore, be careful in how you specify your Prefix / Suffix and the files they indicate. For example, in the following setup of S3 triggers, AWS would raise errors because of overlap with `.jsonl` files in `/modelA/datacapture` (triggers A + C) as well as overlap with `.tar.gz` files in `/modelA` (triggers B + C): + +> Trigger A: (Prefix: `s3://bucket/modelA/datacapture`) (Suffix: `.jsonl`) +> +> Trigger B: (Prefix: `s3://bucket/modelA`) (Suffix: `.tar.gz`) +> +> Trigger C: (Prefix: `s3://bucket/modelA`) (Suffix: Unspecified) + + +In the above cases, AWS will still successfully create the Lambda, but will then raise the following error at the top of their UI: + +> Your Lambda function "lambda-function-name" was successfully created, but an error occurred when creating the trigger: Configuration is ambiguously defined. Cannot have overlapping suffixes in two rules if the prefixes are overlapping for the same event type. + + +#### Lambda Code + +```python +import urllib.parse +import boto3 +import os +import requests + +s3 = boto3.client('s3') + +ARTHUR_MODEL_ID = os.environ["ARTHUR_MODEL_ID"] # 12345678-1234-1234-1234-1234567890ab +ARTHUR_HOST = os.environ["ARTHUR_HOST"] # https://app.arthur.ai/ +if ARTHUR_HOST[-1] != '/': + ARTHUR_HOST += '/' # Ensure trailing slash exists + +# TODO BY USER +# FILL IN CODE TO RETRIEVE AN ARTHUR API KEY +ARTHUR_ACCESS_TOKEN = os.environ["ARTHUR_ACCESS_TOKEN"] + +ARTHUR_ENDPOINT = f"api/v3/models/{ARTHUR_MODEL_ID}/inferences/integrations/sagemaker_data_capture" + + +def lambda_handler(event, context): + # Get the object from the event + bucket = event['Records'][0]['s3']['bucket']['name'] + key = urllib.parse.unquote_plus(event['Records'][0]['s3']['object']['key'], encoding='utf-8') + + try: + s3_object = s3.get_object(Bucket=bucket, Key=key) + + datacapture_body = s3_object.get('Body') + request_url = urllib.parse.urljoin(ARTHUR_HOST, ARTHUR_ENDPOINT) + print(f"Request: POST {request_url}") + + response = requests.post( + request_url, + files={'inference_data': ('smdatacapture.jsonl', datacapture_body, s3_object['ContentType'])}, + headers={'Authorization': ARTHUR_ACCESS_TOKEN} + ) + print(f"Response: {response.content}") + + except Exception as e: + print(e) + print('Error getting object {} from bucket {}. ' + 'Make sure they exist and your bucket is in the same region as this function.'.format(key, bucket)) + raise e +``` + +### Summary + +Now, with your SageMaker endpoint deployed (with Data Capture configured) and a Lambda function ready for S3 updates, you can send requests to your SageMaker endpoint to generate predictions. The predictions will be logged as files in S3 by Data Capture, and the lambda function will upload the inferences to Arthur where you will be able to see them in the dashboard. diff --git a/files/arthur-docs-markdown/user-guide/integrations/sparkML.md.txt b/files/arthur-docs-markdown/user-guide/integrations/sparkML.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d56beb3899ec22c888669a91869adf6063cb345e --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/integrations/sparkML.md.txt @@ -0,0 +1,215 @@ +## SparkML Integration + +This guide provides an example of integrating with the ArthurAI platform to monitor a SparkML model. We'll use an example dataset to train a SparkML model from scratch, but you could also use an existing Spark Pipeline. + +```python +from pyspark.sql import SparkSession +from pyspark.ml import Pipeline +from pyspark.ml.feature import VectorAssembler +import pyspark.sql.functions as f +from pyspark.ml.classification import LogisticRegression + +import pandas as pd +import numpy as np + +from arthurai import ArthurAI +from arthurai.client.apiv3 import InputType, OutputType, Stage +``` + +### Train and Save SparkML Model + +First, we'll instantiate a Spark session and load in a sample dataset. In this example, we'll use a dataset derived from the famous Boston Housing dataset to build a simple model. + +```python +spark = SparkSession.builder.appName('app').getOrCreate() +data = spark.read.csv('./data/boston_housing.csv', header=True, inferSchema=True) +train, test = data.randomSplit([0.7, 0.3]) +``` + +We'll use a LASSO classification model to try to predict the `is_expensive` column from all the others. This column encodes whether or not a property value was above or below the local average. As preprocessing, we'll use the VectorAssembler class to pull together the input columns into a single numeric feature vector. + +```python +feature_columns = data.columns[:-1] # here we omit the final column +assembler = VectorAssembler(inputCols=feature_columns,outputCol="features") +lasso_classifier = LogisticRegression(featuresCol="features", labelCol="is_expensive", maxIter=10, regParam=0.3, elasticNetParam=1.0) +``` + +Using a Pipeline, we'll combine our preprocessing steps and our ML model, and we'll fit to the training data and save. If you have an existing Spark Pipeline, you can load from disk. + +```python +pipeline = Pipeline(stages=[assembler, lasso_classifier]) +fitted_pipeline = pipeline.fit(train) +fitted_pipeline.write().overwrite().save('./data/models/boston_housing_spark_model_pipeline') +``` + +### Onboard to Arthur + +```python +arthur = ArthurAI(url='https://app.arthur.ai', login="", password="") +``` + +To onboard our model with Arthur, we'll register the schema of the data coming into and out of the model. For simplicity, you can use a Pandas Dataframe for this step. We will take a sample of the SparkDF to the driver, and use this to register the model to Arthur. + +```python +sample_df = train.take(5000).toPandas() +sample_Y = sample_df.loc[['is_expensive']] +sample_X = sample_df.drop('is_expensive', axis=1) +``` + +```python +# instantiate basic model +arthur_model = arthur.model({ + "partner_model_id": "Boston Housing", + "input_type": InputType.Tabular, + "output_type": OutputType.Multiclass, + "is_batch": True}) + +# use pandas DataFrames to register data schema +arthur_model.from_dataframe(sample_X, Stage.ModelPipelineInput) +arthur_model.add_binary_classifier_output_attributes( + positive_predicted_attr='expensive', + pred_to_ground_truth_map={ + 'prediction_expensive': 'ground_truth_expensive', + 'prediction_cheap': 'ground_truth_cheap' + }, + threshold=0.75 +) +``` + +The `from_dataframe()` method will inspect your dataset and infer the input schema, datatypes, and sample statistics. You can review the model structure and see if any fixes are needed. + + +```python +arthur_model.review() +``` + +```python +# chas and rad were inferred as categorical, lets change those to be continuous +arthur_model.get_attribute('chas', Stage.ModelPipelineInput).set(categorical=False) +arthur_model.get_attribute('rad', Stage.ModelPipelineInput).set(categorical=False) +arthur_model.review() +``` + +**Monitoring for bias** +For any attributes that you want to monitor for bias, you set the `monitor_for_bias` boolean. In fact, these don't have to be model inputs, they can also be of stage NonInputData. +```python +sensitive_attributes = ["Gender", "Race", "Income_Bracket"] +for attribute_name in sensitive_attributes: + arthur_model.get_attribute(attribute_name, Stage.ModelPipelineInput).monitor_for_bias = True +``` + +**Save** +Now you're ready to save your model and finish onboarding. +```python +arthur_model.save() +``` + + +### Set reference data +You can set a baseline dataset in order to speed up the calculation of data drift and inference anomaly scoring. +This reference set is typically the training set the model was fitted to, or a subsample. You can use either a pandas +DataFrame or a directory of parquet files. The reference data can include model input features, ground truth features +or model predictions on training sets. However, it is recommended that only model input features are provided. +```python +arthur_model.set_reference_data(directory_path="./data/august_training_data/") +``` + +(sparkml_explainability)= +### Enabling Explainability for SparkML +To enable explainability, you'll supply a python file that implements a `predict()` function for a single observation +(a numpy array). This predict function can contain anything you need, including loading a serialized model, +preprocessing/transformations, and making a final prediction. The returned result should be a numpy array. You'll also +supply a requirements file for all the dependencies for running an inference through your model. + +For more details around enabling explainability, see the {doc}`/user-guide/walkthroughs/explainability` guide. +Below we provide a Spark specific example. + +The first step is to save your SparkML model and pipeline so it can be imported for use in the `predict()` function + +```python +fitted_pipeline.write().overwrite().save('./data/models/boston_housing_spark_model_pipeline') +``` + +Next is to create your `predict()` function. + +```python +# entrypoint.py + +import pandas as pd +import numpy as np +from pyspark.sql import SparkSession +from pyspark.ml import PipelineModel + + +# To start the spark session on the model server specify the master url as local. +# By default this will run spark using 1 thread, to increase threads you can specify +# local[x] where x is the number of threads. When allocating more compute and memory to the spark +# session be sure to increase the amount allocated to the model server when calling ArthurModel.enable_explainability() +# in the sdk (by default 1 cpu and 1gb of memory is allocated to the model server). + +spark = SparkSession.builder.master('local').appName('app').getOrCreate() +loaded_pipeline = PipelineModel.load("./data/models/boston_housing_spark_model_pipeline") + + +def predict(input_data): + col_names = ['crim','zn','indus','chas','nox','rm','age','dis','rad','tax','ptratio','b','lstat'] + input_df = pd.DataFrame(input_data, columns=col_names) + spark_df = spark.createDataFrame(input_df) + predictions = loaded_pipeline.transform(spark_df) + return np.array([float(x.prediction) for x in predictions.select('prediction').collect()]) +``` + +You are then ready to {ref}`enable explainability ` + +```python +arthur_model.enable_explainability( + df=sample_df, + project_directory='.', + user_predict_function_import_path='entrypoint', + requirements_file='requirements.txt') +``` + +### Send Batch of Inferences + +Once your model has been onboarded, it is ready to receive inferences and model telemetry. There are some standard inputs needed to identify inferences and batches. + +* First, each inference needs a unique identifier so that it can later be joined with ground truth. Include a column named **partner_inference_id** and ensure these IDs are unique across batches. For example, if you run predictions across your customer base on a daily-batch cadence, then a unique identfier could be composed of your customer_id plus the date. +* Second, each inference needs to be associated with a **batch_id**, but this id will be shared among one or more inferences. +* Finally, each inference needs an **inference_timestamp** and these don't have to be unique. + +Additionally, the predictions/scores from your model should match the column names in the registered schema. If we take a look above at arthur_model.review() we'll recall that columns we created correspond to the clasiffier's output probabilities over the classes ("prediction_cheap" and "prediction_expensive") and the corresponding ground truth over the possible classes in one-hot form ("ground_truth_cheap" and "ground_truth_expensive"). + +We will process a batch of datapoints through the Pipeline and save the inputs (and predictions) to parquet. We will do the same for the ground truths. + +```python +loaded_pipeline = PipelineModel.load("./data/models/boston_housing_spark_model_pipeline") +inferencesDF = loaded_pipeline.transform(test).withColumnRenamed("probability", "prediction_expensive") + +uuidUdf= udf(lambda : str(uuid.uuid4()), StringType()) +inferencesDF = inferencesDF.withColumn('partner_inference_id', uuidUdf()) + +# add required columns +inferencesDF["inference_timestamp"] = datetime.utcnow() +inferencesDF["batch_id"] = "inferences_batch_001" +inference_df["partner_inference_id"] = ... + +# write inferences +inferencesDF.write.parquet("./data/inference_files/inferences.parquet") + +# write ground truths +ground_truth_DF = test.select(["ground_truth_cheap", "ground_truth_expensive"]) +ground_truth_DF["partner_inference_id"] = ... +ground_truth_DF["ground_truth_timestamp"] = datetime.utcnow() +ground_truth_DF["batch_id"] = "gt_batch_001" +ground_truth_batch.write.parquet("./data/ground_truth_files/ground_truth.parquet") +``` + +With our model's inputs and outputs save as parquet, we upload a batch by pointing to the directory containing one or more parquet files. The directory will be traversed and all parquet files will be joined into the corresponding batch. Note, the model inputs and predictions will be uploaded separately from the ground truth. +```python +arthur_model.send_bulk_inferences(directory_path='./data/inference_files/') +``` + +You can separately upload ground truths for each inference. Every row in the ground truth file(s) should have an `external_id` column that matches any IDs you create for the inferences. +```python +arthur_model.send_bulk_ground_truths(directory_path='./data/ground_truth_files/') +``` diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/bias_monitoring.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/bias_monitoring.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..d6643ba434baa071cc4a9e00a502579cad779d33 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/bias_monitoring.md.txt @@ -0,0 +1,49 @@ +# Bias Monitoring + +There are two components to Arthur's approach to bias: monitoring and mitigation. + +Monitoring for bias is the process of measuring the disparity of a model on different subgroups of a population. **_This guide is a walkthrough on bias monitoring._** + +To learn more about Arthur's bias mitigation process, see the explanation of our current mitigation methods from an algorithms perspective {ref}`here `. + +## Monitoring Attributes for Bias +For some of the attributes in your model, you may want to pay particular attention to how your model's outputs are potentially different for each subpopulation of that attribute. +We refer to this as _monitoring an attribute for bias_. A common example might be so-called _protected basis variables_ such as race, age or gender. But you can define any attributes that are important for your business case and select them for bias monitoring. + + +### Model Input Attributes +If you have already registered a few input attributes of your model, you can set a subset of them to be monitored for bias. For a categorical variable, each possible level of the attribute will be treated as a distinct sub-population for analysis. For example, if you had an attribute for "Gender" which comprised the three possible values `Male`, `Female` and `Non-Binary`, then you would simply add the following to your model onboarding. + +```python +arthur_model.get_attribute("SEX", stage=Stage.ModelPipelineInput + ).monitor_for_bias = True +``` + +For a continuous variable, you need to break the continuous range into a fixed number of groupings so that we can create sub-populations. You can do this by providing cutoff thresholds for each grouping. For example, if we have a continuous attribute called `AGE`, we can create three age brackets such as `< 35`, `35 - 55`, and `> 55`. We create these groups by providing the upper-cutoff values for each group. +```python +arthur_model.get_attribute("AGE", stage=Stage.ModelPipelineInput + ).monitor_for_bias = True +arthur_model.get_attribute("AGE", stage=Stage.ModelPipelineInput + ).set(bins = [None, 35, 55, None]) +``` + +### Non-Input Attributes +You can monitor for bias even if the sensitive attributes are not direct input to your model. +```python +arthur_model.get_attribute("SEX", stage=Stage.NonInputData + ).monitor_for_bias = True +``` +Then, when you send inferences, you can include this side information in the `NonInputData` fields. This allows you to determine if your model potentially has a disparate impact on certain sub-populations. + +### Viewing Fairness Metrics + +On the Arthur Dashboard, you can view the outcomes of your model with respect to the sensitive attributes and sub-populations you defined. + +We have also defined a few convenience functions on the `ArthurModel` object through the [`bias.metrics` submodule](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.bias.bias_metrics.BiasMetrics.html#arthurai.core.bias.bias_metrics.BiasMetrics): + +```python +arthur_model.bias.metrics.demographic_parity('') +arthur_model.bias.metrics.group_confusion_matrices('') +``` + +Finer-grained metrics can also be achieved through our {doc}`query endpoint `. diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/enrichments.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/enrichments.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..5e8273cb5ce504be7e1a5c9ec18b8183f943dc58 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/enrichments.md.txt @@ -0,0 +1,266 @@ +# Enrichments + +This guide will outline how to enable, disable, and configure Enrichments. + + +Enrichment | Constant | Description +---|---|--- +[Explainability](#explainability) | `Enrichment.Explainability` | Generates feature importance scores for inferences. Requires user to provide model files. +[Anomaly Detection](#anomaly-detection) | `Enrichment.AnomalyDetection` | Calculates a multivariate anomaly score on each inference. Requires reference set to be uploaded. +[Hotspots](#hotspots) | `Enrichment.Hotspots` | Finds data points which the model underperforms on. This is calculated for each batch or over 7 days worth of data for streaming models. +[Bias Mitigation](#bias-mitigation) | `Enrichment.BiasMitigation` | Calculates possible sets of group-conditional thresholds that may be used to produce fairer classifications. + + +(enrichments_explainability)= +## Explainability + +### Compatibility + +Explainability is supported for all InputTypes, and all OutputTypes except for ObjectDetection. + +### Usage + +To enable, we advise using the helper function `model.enable_explainability()` which simplifies some of the steps of updating the explainability Enrichment. For more detail, see our guide on {ref}`enabling explainability ` +Once enabled, you can use the generic functions (`model.update_enrichment()` or `model.update_enrichments()`) to update and change configuration, or disable explainability. + +```python +# view configuration +arthur_model.get_enrichment(Enrichment.Explainability) + +# enable +arthur_model.enable_explainability( + df=X_train.head(50), + project_directory="/path/to/model_code/", + requirements_file="example_requirements.txt", + user_predict_function_import_path="example_entrypoint" +) + +# update configuration +config_to_update = { + 'explanation_algo': 'shap', + 'streaming_explainability_enabled': False +} +arthur_model.update_enrichment(Enrichment.Explainability, True, config_to_update) + +# disable +arthur_model.update_enrichment(Enrichment.Explainability, False, {}) +``` + +### {doc}`Explainability Walkthrough ` + +See our {doc}`explainability walkthrough ` for a thorough guide on setting up the explainability enrichment. + +--- +(enrichments_anomaly_detection)= +## Anomaly Detection + +### Compatiblity + +Anomaly Detection can be enabled for models with any InputType and OutputType. + +Only a reference set is required - this can be a set of the model's train or test data. Once a reference set is uploaded, anomaly scores are calculated automatically. + +### Usage + + +```python +# view current configuration +arthur_model.get_enrichment(Enrichment.AnomalyDetection) + +# enable +arthur_model.update_enrichment(Enrichment.AnomalyDetection, True, {}) + +# disable +arthur_model.update_enrichment(Enrichment.AnomalyDetection, False, {}) +``` + +### Configuration + +No additional configuration is needed for Anomaly Detection. + +### {ref}`Algorithm ` + +See the explanation of our anomaly detection functionality from an algorithms perspective {ref}`here `. + +--- +(enrichments_hotspots)= +## Hotspots + +When a system has high-dimensional data, finding the right data input regions such troubleshooting becomes a difficult problem. Hotspots automates identifying regions associated with poor ML performance to significantly reduce time and error of finding such regions. + + +### Compatibility + +Hotspots can only be enabled for tabular binary classifiers (that is, models with Tabular input types, Multiclass output +types, and at most two predicted value / ground truth attributes). + +If your model sends data in batches, hotspot trees +will be created for each batch that has ground truth uploaded. For streaming models hotspot trees will be generated on +for inferences with ground truth on a weekly basis (Monday to Sunday). + +### Usage + +```python +# view current configuration +arthur_model.get_enrichment(Enrichment.Hotspots) + +# enable +arthur_model.update_enrichment(Enrichment.Hotspots, True, {}) + +# disable +arthur_model.update_enrichment(Enrichment.Hotspots, False, {}) +``` + +### Configuration + +There is currently no additional configuration for Hotspots. + + +### Fetching Hotspots + +If we have hotspots enabled, we fetch hotspots via the [API endpoint](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/enrichments/paths/~1models~1{model_id}~1enrichments~1hotspots~1find/get). From the SDK, with a loaded Arthur model, we can fetch hotspots as such: + +```python +model.find_hotspots(metric="accuracy", threshold=.7, batch_id="batch_2903") +``` + +The method signature is as follows: + +```python +def find_hotspots(self, + metric: AccuracyMetric = AccuracyMetric.Accuracy, + threshold: float = 0.5, + batch_id: str = None, + date: str = None, + ref_set_id: str = None) -> Dict[str, Any]: + """Retrieve hotspots from the model + :param metric: accuracy metric used to filter hotspots tree by, defaults to "accuracy" + :param threshold: threshold for of performance metric used for filtering hotspots, defaults to 0.5 + :param batch_id: string id for the batch to find hotspots in, defaults to None + :param date: string used to define date, defaults to None + :param ref_set_id: string id for the reference set to find hotspots in, defaults to None + :raise: ArthurUserError: failed due to user error + :raise: ArthurInternalError: failed due to an internal error + """ +``` + +### Interpreting Hotspots + +For a toy classification model with two inputs X0 and X1, a returned list of hotspots could be as follows: + +```json +[ + { + "regions": { + "X1": { + "gt": -7.839450836181641, + "lte": -2.257883667945862 + }, + "X0": { + "gt": -6.966174602508545, + "lte": -2.8999762535095215 + } + }, + "accuracy": 0.42105263157894735 + }, + { + "regions": { + "X1": { + "gt": -7.839450836181641, + "lte": -5.140551567077637 + }, + "X0": { + "gt": 4.7409820556640625, + "lte": "inf" + } + }, + "accuracy": 0.35714285714285715 + }, + { + "regions": { + "X1": { + "gt": 3.8619565963745117, + "lte": 6.9831953048706055 + }, + "X0": { + "gt": -0.9038164913654327, + "lte": 0.9839221835136414 + } + }, + "accuracy": 0.125 + } +] +```` + +Here we have three hotspots. Taking the last hotspot, the input region is `-.90 < X0 <= .98` and `3.86 < X1 <= 6.98`, and the datapoints in that particular region have an accuracy of .125. This now allows the user to immediately investigate the "needle in the haystack" immediately. + +**{ref}`Algorithm `** + +See the explanation of our Hotspots functionality from an algorithms perspective {ref}`here `. + +--- +(enrichments_bias_mitigation)= +## Bias Mitigation + +### Compatibility + +Bias Mitigation can be enabled for binary classification models of any input type, as long as at least one attribute +is marked as `monitor_for_bias=True`, and a reference set uploaded to Arthur. + +### Usage + + +```python +# view current configuration +arthur_model.get_enrichment(Enrichment.BiasMitigation) + +# enable +arthur_model.update_enrichment(Enrichment.BiasMitigation, True, {}) +# or +arthur_model.enable_bias_mitigation() +``` + +Enabling Bias Mitigation will automatically train a mitigation model for all attributes marked as `monitor_for_bias=True`, for the constraints demographic parity, equalized odds, and equal opportunity. + +### Configuration + +There is currently no additional configuration for Bias Mitigation. + +### {ref}`Algorithm ` + +See the explanation of our bias mitigation functionality from an algorithms perspective {ref}`here `. + +--- +(enrichments_configuring_multiple_enrichments)= +## Configuring Multiple Enrichments + +### Viewing Current Enrichments + +You can use the SDK to fetch all enrichment settings for a model: + +```python +arthur_model.get_enrichments() +``` + +This will return a dictionary containing the configuration for all available enrichments: + +```python +{'anomaly_detection': {'enabled': True, 'config': {}}, + 'bias_mitigation': {'enabled': False}, + 'explainability': {'enabled': False}, + 'hotspots': {'enabled': False}} +``` + +### Updating Enrichment Configurations + +You can configure multiple enrichments at once: + +```python +enrichment_configs = { + Enrichment.Explainability: {'enabled': False, 'config': {}}, + Enrichment.AnomalyDetection: {'enabled': True, 'config': {}} +} +arthur_model.update_enrichments(enrichment_configs) +``` + + diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/explainability.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/explainability.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..22c16d1fe2510714010a4598f1501f7524304fb3 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/explainability.md.txt @@ -0,0 +1,309 @@ +# Explainability + +Arthur can automatically calculate explanations (feature importances) for every prediction your model makes. In order to make this possible we package up your model in a way that allows us to call its `predict` function, which allows us to calculate explanations. We require a few things from your end: + +* A python script that wraps your models `predict` function + * For Image models, a second function, `load_image` is also required (see {ref}`cv_explainability`). +* A directory containing the above file, along with any serialized model files, and other supporting code +* A `requirements.txt` with the dependencies to support the above + +This guide will walk through setting everything up, and then using the SDK to enable explainability. + +--- + +## Setting up Project Directory + +### Project Structure +Here is an example of what your project directory might look like. + +``` +|-- model_folder/ +| |-- data/ +| | |-- training_data.csv +| | |-- testing_data.csv +| |-- requirements.txt +| |-- model_entrypoint.py +| |-- utils.py +| |-- serialized_model.pkl +``` + +### Requirements File +Your project requirements and dependencies can be stored in any format you like, such as the typical `requirements.txt` file, or another form of dependency management. + +This should contain all packages your model and predict function need to run. + +```{note} You do not need to include the arthurai package in this requirements file, we supply that. +``` + +``` +# example_requirements.txt + +pandas==0.24.2 +numpy==1.16.4 +scikit-learn==0.21.3 +torch==1.3.1 +torchvision==0.4.2 +``` + +It is advised to pin the specific versions your model requires. If no version is pinned we will use the latest version. This can cause issues if the latest version is not compatible with the version used to build your model. + + +### Prediction Function +We need to be able to send new inferences to your model to get predictions and generate explanations. For us to have access to your model, you need to create an `entrypoint` file that defines a `predict()` method. + +The exact name of the file isn't strict, so long as you specify the correct name when you enable explainability (see below). The only thing that does matter is that this file implements a `predict()` method. In most cases, if you have a previously trained model, this `predict()` method will likely just invoke the prediction from your trained model. + +```python +# example_entrypoint.py + +sk_model = joblib.load("./serialized_model.pkl") + +def predict(x): + return sk_model.predict_proba(x) +``` + +_See the {ref}`SparkML Integration Guide ` for an example using a SparkML model._ + +This predict method can be as simple or complicated as you need, so long as you can go from raw input data to a model output prediction. +Specifically, in the case of a binary classifier, we expect a 2-d array where the first column indicates `probability_0` for each input, and the second column indicates `probability_1` for each input. In the case of a multiclass classifier with *n* possible labels, we expect an *n*-d array where column *i* corresponds to the predicted probability that each input belongs to class *i*. + +### Preprocessing for Prediction +Commonly, a fair amount of feature processing and transformation will need to happen prior to invoking your actual `model.predict()`. This might include normalizations, rescaling, one-hot encoding, embedding, and more. Whatever those transformations are, you can make them a part of this `predict()` method. Alternatively, you can wrap all those transformations into a helper function. + +```python +# example_entrypoint.py +from utils import pipeline_transformations + +sk_model = joblib.load("./serialized_model.pkl") + +def predict(x): + return sk_model.predict_proba(pipeline_transformations(x)) +``` + +--- +(enabling_explainability)= +## Enabling Explainability + +Enabling explainability can be done using the SDK function `arthur_model.enable_explainability`, which takes as input a sample of your model's data (to train the explainer), and which takes as input the files that contain your model's predict function and necessary environment. +```python +arthur_model.enable_explainability( + df=X_train.head(50), + project_directory="/path/to/model_folder/", + requirements_file="requirements.txt", + user_predict_function_import_path="model_entrypoint", + ignore_dirs=["folder_to_ignore"] # optionally exclude directories within the project folder from being bundled with predict function +) +``` + +The above provides a simple example. For a list of all configuration options and details around them, see the {ref}`explainability entry in the Enrichment guide `. + +Notes about above example: +1. [joblib](https://joblib.readthedocs.io/en/latest/generated/joblib.load.html) is a Python library that will allow you to reconstruct your model from a serialized pickle file. +1. `X_train` is your trained model dataframe. +1. `user_predict_function_import_path` is the **Python** path to import the entrypoint file as if you imported it into the python program that is running enable_explainability. + +### Configuration Requirements + +When going from `disabled` to `enabled`, you will need to include the required configuration settings. Once the explainability enrichment has been enabled, you can update the non-required configuration settings without re-supplying required fields. +When disabling the explainability enrichment, you are not required to pass in any config settings. + +**Configuration** + +Setting | Required | Description +---|---|--- +`df` | X | The dataframe passed to the explainer. Should be similar to, or a subset of, the training data. Typically small, ~50-100 rows. +`project_directory` | X | The path to the directory containing your predict function, requirements file, model file, and any other resources need to support the predict function. +`user_predict_function_import_path` | X | The name of the file containing the predict function. Do not include `.py` extension. Used to import the predict function. +`requirements_file` | X | The name of the file containing pip requirements for predict function. +`python_version` | X | The Python version to use when executing the predict function. This is automatically set to the current python version when using `model.enable_explainability()`. +`sdk_version` | X | The `arthurai` version used to make the enable request. This is automatically set to the currently installed SDK version when using `model.enable_explainability()`. +`explanation_algo` | | The explanation algorithm to use. Valid options are `'lime'` or `'shap'`. Default value of `'lime'`. +`explanation_nsamples` | | The number perturbed samples used to generate the explanation. For a smaller number of samples, the result will be calculated more quickly but may be less robust. It is recommended to use at least 100 samples. Default value of 2000. +`inference_consumer_score_percent` | | Number between 0.0 and 1.0 that sets the percent of inferences to compute an explanation score for. Only applicable when `streaming_explainability_enabled` is set to `true`. Default value of 1.0 (all inferences explained). +`streaming_explainability_enabled` | | If true, every inference will have an explanation generated for it. If false, explanations are available on-demand only. +`ignore_dirs` | | List of paths to directories within `project_directory` that will not be bundled and included with the predict function. Use to prevent including irrelevant code or files in larger directories. + +--- +(cv_explainability)= +## CV Explainability + +```{note} Explainability is currently available as an enrichment for classification, multi-labeling, and regression CV models, but not object detection CV models. +``` +In your `model_entrypoint.py` for Multiclass Image models, in addition to the `predict()` function, there is a second function which is required: `load_image()`. This function should take in +a string, which is a path to an image file. The function should return the image in a `numpy` array. +Any image processing, such as converting to grey scale, should also happen in this function. This is because +Lime (the explanation algorithm used behind the scenes) will create variations of this array to generate explanations. +However any transformation resulting in a non-numpy array, should happen in the `predict` function, such as converting to a Tensor. + +No image resizing is required. As part of onboarding an image model, `pixel_height` and `pixel_width` are set +as metadata on the model. When ingesting, Arthur will automatically resize the image to the configured size, and pass this resized image path to the `load_image` function. + +Below is a full example file for an Image model, with both `load_image` and `predict` defined. +Imports and class definitions are omitted for brevity. + +```python +# example_entrypoint.py +import ... + +class MedNet(nn.Module): + ... + +# load model using custom user defined class +net = MedNet() +path = pathlib.Path(__file__).parent.absolute() +net.load_state_dict(torch.load(f'{path}/pretrained_model')) + +# helper function for transforming image +def quantize(np_array): + return np_array + (np.random.random(np_array.shape) / 256) + +def load_image(image_path): + """Takes in single image path, and returns single image in format predict expects + """ + return quantize(np.array(Image.open(image_path).convert('RGB')) / 256) + +def predict(images_in): + """Takes in numpy array of images, and returns predictions in numpy array. + + Can handle both single image in `numpy` array, or multiple images. + """ + batch_size, pixdim1, pixdim2, channels = images_in.shape + raw_tensor = torch.from_numpy(images_in) + processed_images = torch.reshape(raw_tensor, (batch_size, channels, pixdim1, pixdim2)).float() + net.eval() + with torch.no_grad(): + return net(processed_images).numpy() +``` + +--- +(nlp_explainability)= +## NLP Explainability + +Enabling explainability for NLP models follows the same process for Tabular models. + +```{note} An important choice for NLP explainability is the text_demiliter parameter, since this delimiter determines how tokens will be perturbed when generating explanations. +``` + +Here is an example `entrypoint.py` file which loads our NLP model and defines a `predict` function that the explainer will use: +```python +model_path = os.path.join(os.path.dirname(__file__), "model.pkl") +model = joblib.load(model_path) + +def predict(fvs): + # our model expects a list of strings, no nesting + # if we receive nested lists, unnest them + if not isinstance(fvs[0], str): + fvs = [fv[0] for fv in fvs] + return model.predict_proba(fvs) +``` + +--- + +## Troubleshooting + +### AttributeError When Loading Predict Function + +While this can be an issue with any model type, it is common to see when using sk-learn objects that take in custom user functions. +We will use `TfidfVectorizer` as an example, which is a commonly used vectorizer for NLP models, that often utilizes custom user functions. + +A `TfidfVectorizer` accepts a user defined `tokenize` function, which is used to split a text string into tokens. + +**Problem** + +Say this code was used to create your model. +```python +# make_model.py + +def tokenize(text): + # tokenize and lemmatize + doc = nlp(txt) + tokens = [] + for token in doc: + if not token.is_stop and not token.is_punct \ + and not token.is_space and token.lemma_ != '-PRON-': + tokens.append(token.lemma_) + return tokens + +def make_model(): + # here we pass a custom function to an sklearn object + vectorizer = TfidfVectorizer(tokenizer=tokenize) + vectorizer.fit(X_train) + model = LogisticRegression() + model.fit(vectorizer.transform(X_train)) + + pipeline = make_pipeline(vectorizer, model) + joblib.dump(pipeline, 'model.pkl') + +if __name__ == "__main__": + make_model() +``` + +Now you create this entrypoint file to enable explainability: +```python +# entrypoint.py + +model = joblib.load("./model.pkl") + +def predict(fv): + return model.predict_proba(fv) +``` + +Now when the SDK imports `entrypoint` to test the function, the following error gets thrown: + +`AttributeError: module '__main__' has no attribute 'tokenize'` + +What happens is that Python failed to serialize the custom function, only the reference to how it was imported. +Which in this case, it was just top level in the model creation script (hence `__main__.tokenize` in the error). +This function doesn't exist in `entrypoint`, and so the error is thrown. + +**Solution** + +To solve, you need to pull out `tokenize` into its own module, that can be imported from both `create_model.py` +and also in `entrypoint.py`. + +```python +# model_utils.py + +def tokenize(text): + # tokenize and lemmatize + doc = nlp(txt) + tokens = [] + for token in doc: + if not token.is_stop and not token.is_punct \ + and not token.is_space and token.lemma_ != '-PRON-': + tokens.append(token.lemma_) + return tokens +``` + +```python +# create_model.py +from model_utils import tokenize + +def make_model(): + # here we pass a custom function to an sklearn object + vectorizer = TfidfVectorizer(tokenizer=tokenize) + vectorizer.fit(X_train) + model = LogisticRegression() + model.fit(vectorizer.transform(X_train)) + + pipeline = make_pipeline(vectorizer, model) + joblib.dump(pipeline, 'model.pkl') + +if __name__ == "__main__": + make_model() +``` + +```python +# entrypoint.py +from model_utils import tokenize + +model = joblib.load("./model.pkl") + +def predict(fv): + return model.predict_proba(fv) +``` + +Now, when Python serializes the model, it stores the reference as `model_utils.tokenize`, which is also imported within +`entrypoint.py` and therefore no error is thrown. + +Now everything will work, but both `model_utils.py` AND `entrypoint.py` must be included in the directory passed to `enable_explainability()`. \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/index.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..2d82a3d14f3aa1076fd9b5a645bb409adaa7480a --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/index.md.txt @@ -0,0 +1,30 @@ +# Walkthroughs + +These guides walk you through common tasks central to the Arthur platform. + +## {doc}`Model Onboarding ` +This walkthrough shows the steps of onboarding a model to Arthur. + +## {doc}`Metrics & Alerts ` +This walkthrough covers model metrics and alerts, for configuring how you define model performance and what issues you get notified about. + +## {doc}`Enrichments ` +This walkthrough shows the steps of turning on and configuring **_enrichments_**, which are additional services that the Arthur platform provides for state-of-the-art proactive model monitoring. + +## {doc}`Explainability ` +This walkthrough shows the process of explaining models using feature importance scores. + +## {doc}`Bias Monitoring ` +This walkthrough shows the process of identifying bias in model performance between groups of your data. + + +```{toctree} +:hidden: +:maxdepth: 2 + +Model Onboarding +Metrics & Alerts +Enrichments +Explainability +Bias Monitoring +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/metrics_alerts.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/metrics_alerts.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a1a6c9ee919d1e55fd0e65fb43c1fb487cd1c1e0 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/metrics_alerts.md.txt @@ -0,0 +1,488 @@ +(alerts)= +# Metrics & Alerts + +Arthur Metrics and Alerts offer a powerful framework for measuring, alerting on, and exploring your model performance. +This walkthrough will explore these critical features in depth, introducing you to their usage and how to leverage +them to get the most from your machine learning models. + + +## Metrics + +Metrics are functions for measuring model performance. They might compare predicted values to ground truth, measure +distributional shift, evaluate model fairness, surface explainability trends, track feature distributions, inference +volumes, or anything else you can imagine. Metrics are a foundational part of evaluating and exploring your models, and +Arthur's powerful Metrics API gives you the defaults you need to hit the ground running as well as the flexiblity to +define model performance however it best suits your business. + +Arthur's metrics are defined as template queries in our {doc}`Query API ` format. +These template queries are evaluated with your specified parameters, filters, and rollup. For example, when you're +viewing a Feature Drift chart in the UI, behind the scenes the Arthur dashboard is: + +- evaluating the Feature Drift metric for your model +- specifying your selected Drift Metric parameter (e.g. "PSI") and your specified Drift Attribute parameter(s) +(e.g. "Age" and "FICO Score" input attributes) +- specifying your selected timeframe as a filter over the "inference_timestamp" field +- specifying your selected rollup of "day", "hour", etc. to determine the granularity of the graph (or "batch_id" for + batch models) + +### Default Metrics + +Arthur creates many default metrics that are commonly used to evaluate model performance, and these are tailored for +each model you create. For example, classification models will get metrics like Accuracy and F1 while regression models +will use other evaluation functions like RMSE and Average Prediction. Tabular models will get univariate and +multivariate drift metrics, while CV and NLP models will only get multivariate. + +### Fetching Metrics + +If you have the metric ID handy, you can send a GET request to `/models/{model_id}/metrics/{metric_id}`. + +Otherwise, you can send a GET request to `/models/{model_id}/metrics/` with certain filters. + +* `expand` - If set to `"type"` will return the type with each metric. +* `default` - If set to True will return only metrics that are automatically created by default for your model. +* `type` - MetricType to filter metric query with. +* `metric_name` - Metric name filter to use in metric search. +* `attribute_name` - Attribute name filter to use in metric search. + +Query Request: +```json +{ + "expand [Optional]": "type", + "default [Optional]": " [bool]", + "type [Optional]": "[model_output_metric|model_input_data_metric|model_performance_metric|model_data_drift_metric]", + "metric_name [Optional]": " [string]", + "attribute_name [Optional]": " [string]" +} +``` + +If using the SDK, you may call the `get_metrics()` method from your Arthur model. + +### Evaluating Metrics + +You can evaluate you metrics by sending a POST request to `/models/{model_id}/metrics/{metric_id}/result`. The metric +evaluation endpoint makes it easy to get results for your metrics in a format that's easy to digest and plot. + +Query Request: +```json +{ + "parameters [Optional]": "[object]", + "group_by [Optional]": "[array]", + "filters [Optional]": "[array]", + "rollup [Optional]": "[MINUTE|HOUR|DAY|MONTH|YEAR|REFERENCE|BATCH_ID]" +} +``` +The `parameters` object maps from parameter names to values, and you can specify multiple values in your request. +You'll receive a list of metric result objects, one for each combination of parameters you specified. + +The `group_by` array contains a list of attributes to group the results over. If you supply one or more attribute +names, your list of metric result objects will also be broken out for each value in each group you specified. For +categorical attributes, these groups will be the values in each category. For continuous attributes, they'll be +bucketed into deciles. + +The `filters` array contains a list of filters to apply to the data being evaluated, in the same format as our +{ref}`Query Endpoint Filters `. + +The `rollup` specifies how to group the results. If you specify no `rollup` value a single result will be returned for +all the inference data matching any filters, similarly if you specify `REFERENCE` rollup a single result will be +returned for all the reference data matching any filters. Other rollup settings will group the results by the specified +value (e.g. by each hour or batch). + +#### Example: Evaluating Drift + +For example, to evaluate Feature Drift for two attributes, for each month since the beginning of 2021 UTC, you could +use the following query: + +```json +{ + "parameters": { + "feature_attr": ["attr_1", "attr_2"] + }, + "filters": [ + { + "property": "inference_timestamp", + "comparator": "gte", + "value": "2021-01-01T00:00:00Z" + } + ], + "rollup": "MONTH" +} +``` + +The result would look like this: + +```json +{ + "filters": [ + { + "comparator": "gte", + "property": "inference_timestamp", + "value": "2021-01-01T00:00:00Z" + } + ], + "name": "Feature Drift", + "results": [ + { + "name": "attr_1", + "parameters": { + "drift_metric": "PSI", + "feature_attr": "attr_1" + }, + "values": [ + { + "attr_1": 0.1, + "rollup": "2021-01-01T00:00:00Z" + }, + { + "attr_1": 0.2, + "rollup": "2021-02-01T00:00:00Z" + }, + "..." + ] + }, + { + "name": "attr_2", + "parameters": { + "drift_metric": "PSI", + "feature_attr": "attr_2" + }, + "values": [ + { + "attr_1": 0.001, + "rollup": "2021-01-01T00:00:00Z" + }, + { + "attr_1": 0.15, + "rollup": "2021-02-01T00:00:00Z" + }, + "..." + ] + } + ] +} +``` + +Each combination of parameters returns its own result: if we'd specified KLDivergence in addition to our PSI drift +metric, we would have four result objects. Within each result object, we get back a list of values, each of which +contains a map with two fields: the metric value and the rollup value. + +### Creating Custom Metrics + +You can define a custom metric for your model by sending a POST request to the dedicated metrics endpoint at +`/models/{model_id}/metrics`. See [our API Reference](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/metrics/paths/~1models~1%7Bmodel_id%7D~1metrics/post) +for the full specification. The basis of the metric is the template query, which should have the following properties: + +1. The query should only return a single value. For example, the query should not return a row for each inference or +time-series data or scores for multiple attributes. +1. The query should generally not include filters. You can define filters when evaluating a metric, so the definition +should be general. +1. The query may include parameters, which are denoted by `{{ param_name }}` template values in the query definition and + have corresponding entries in the `parameters` field on the metric definition. + +The full JSON request body has this format: + +```json +{ + "name": " [string]", + "query": " [dict]", + "endpoint": " [string]", + "parameters": " [string]" +} +``` + +* `name` - Name of the metric to create. +* `query` - Query which makes up the metric. +* `endpoint` - Endpoint determining class of metric. If not data drift query, then `/models/{model_id}/inference/query`, + else `/models/{model_id}/inference/data_drift` +* `parameters` - Parameters included in the template query with details about their allowed and default values + +If using the SDK, you may call the `create_metric()` method from your Arthur model. + +#### Constructing the Metric + +Your query template should return a single value, which you can imagine as one point on a model peformance graph. +A good way to start building your metric is by hardcoding your parameters with fixed values, and then templating +in the values that you might want to adjust—such as attributes, thresholds, baseline values, or anything else. + + While you're building your template query out, you can test it against Arthur's query endpoint if your plan + suports it, or create your metric and tweak it as needed if your syntax is wrong or executing the metric + identifies issues. You can update existing metrics using the [Metric PUT Endpoint](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/metrics/paths/~1models~1%7Bmodel_id%7D~1metrics~1%7Bmetric_id%7D/put). + +#### Example: Feature Drift + +For example, let's reconstruct the Feature Drift metric that's available by default in the Arthur platform. +We can start with a basic drift metric: + +```json +{ + "endpoint": "/api/v3/models/[model-id]/inferences/query/data_drift", + "name": "Custom Feature Drift", + "query": + { + "base": + { + "source": "reference" + }, + "metric": "PSI", + "num_bins": 10, + "properties": + [ + "[MY_ATTR]" + ], + "target": + { + "source": "inference" + } + } +} +``` + +This will compare all inference data to all reference data. We should be able to create this metric, execute +it, and get a meaningful result. With the creation response we'll get back a Metric ID, which we can then use +to update the metric. We'll edit the query to use templated values, and add parameters for them: + +```json +{ + "query": + { + "base": + { + "source": "reference" + }, + "metric": "{{ drift_metric }}", + "num_bins": 10, + "properties": + [ + "{{ feature_attr }}" + ], + "target": + { + "source": "inference" + } + }, + "parameters": + [ + { + "name": "feature_attr", + "parameter_type": "ATTRIBUTE", + "value_limits": + { + "categorical": + { + "categories": + [ + "[ATTR_1]", + "[ATTR_2]", + "... [all input and non-input attributes]" + ] + } + }, + "default": + [ + "ATTR_1", + "ATTR_2", + "... [five total default attributes]" + ] + }, + { + "name": "drift_metric", + "parameter_type": "STRING", + "value_limits": + { + "categorical": + { + "categories": + [ + "PSI", + "KLDivergence", + "JSDivergence", + "HellingerDistance", + "HypothesisTest" + ] + } + }, + "default": ["PSI"] + } + ] +} +``` + +To create the above metric in one go, we'd simply include the `endpoint` and `name` fields from the first +request in the body and send use it to create the metric. + + +## Alerts + +An alert is a message notifying you that something has occurred with your model. With alerts, Arthur makes it easy to +provide a continuous view into your model by highlighting important changes in model performance. + +An alert is triggered based on an **_alert rule_**, which you define using a metric and a threshold: when the metric +crosses your threshold, the alert is activated. This alert can then be delivered to you via email, highlighted in the +online Arthur UI, and/or accessed via integrations such as PagerDuty and Slack. You may include filters over your +metric when defining an alert rule, and if your metric has parameters you can override the default values. + +Default data drift alerts for Feature and Prediction Drift are automatically created for every feature once there is +reference and inference data sent to Arthur. These alerts are created with dynamic threshold values specific to your +reference dataset from the {ref}`"data_drift" endpoint with "metric": "Thresholds" `. + +The dedicated alerts endpoint is `/models/{model_id}/alert_rules`. + +### Create Alerts + +In addition to the default data drift alerts, we recommend creating custom alerts for your model. At a minimum, we +highly recommend: +- setting a lower-bound Inference Count alert to be notified if your prediction volume falls off +- setting one model evaluation metric (e.g. accuracy or RMSE) if you have ground truth values + +You may also consider setting some reasonable data bound metrics, especially over predicted values. For example, if +you expect your classification model to predict the positive class about half the time, you might set alert rules +to fire if that rate rises above 0.7 or below 0.3. Similarly, if you expect certain input fields to never have null +values you might consider setting alerts if the number of null values rises above zero. + +The parameters available in the API to create an alert rule are: +* `metric_id` - UUID of the metric to use to create an alert rule. +* `name` - A name for the alert rule, a default will be generated if this is not supplied. +* `bound` - Either `"upper"` or `"lower"` +* `threshold` - Threshold of alert rule +* `metric_parameters` - Values for any parameters the metric takes. Note that each parameter may only have a single value. +* `filters` - Filters to apply, to evaluate a metric over a subset of inferences +* `severity` - AlertRuleSeverity of the alert which gets triggered when the metric violates the threshold of the alert + rule. +* `lookback_period` - For streaming models only. The lookback time or "window length" in minutes to use when calculating + the alert rule metric. For example, a lookback period of 5 minutes for an alert rule on average prediction will + calculate average prediction for the past 5 minutes in a rolling window format. This will default to 5 minutes. +* `subsequent_alert_wait_time` - For streaming models only. This is the time in minutes to wait after the most recent + triggered alert before checking if the same alert is triggered. This defaults to 0. + +Query Request: +```json +{ + "metric_id": " [string]", + "bound": "[upper|lower]", + "threshold": " [int|float]", + "metric_parameters": " [object]", + "filters": " [array[object]]", + "severity": "[warning|critical]", + "name [Optional]": " [string]", + "lookback_period [Optional]": " [int|float]", + "subsequent_alert_wait_time [Optional]": " [int|float]" +} +``` + +If using the SDK, you may call the `create_alert_rule()` method from your Arthur model. + +### Get Alerts + +Getting alerts returns a paginated list of rules for the model, and the GET endpoint includes query parameters, +as `/models/{model_id}/alert_rules?page_size={page_size}&page={page}`. + +If using the SDK, you may call the `get_alert_rules` method from your Arthur model. + + +### Update Alerts + +With the alert ID handy, you can send a PATCH request to `/models/{model_id}/alert_rules/{alert_rule_id}`. + +* `bound` - Either `"upper"` or `"lower"` +* `threshold` - Threshold of alert rule +* `severity` - AlertRuleSeverity of the alert which gets triggered when the metric violates the threshold of the alert + rule. +* `lookback_period` - The lookback time or "window length" in minutes to use when calculating the alert rule metric. + For example, a lookback period of 5 minutes for an alert rule on average prediction will calculate average prediction + for the past 5 minutes in a rolling window format. This will default to 5 minutes +* `subsequent_alert_wait_time` - If metric continues to pass threshold this is the time in minutes to wait before + triggering another alert. This defaults to 0. This does not need to be set for batch alerts. +* `enabled` - Whether or not an alert rule is active. Defaults to true. + +Query Request: +```json +{ + "bound [Optional]": "[upper|lower]", + "threshold [Optional]": " [int|float]", + "severity [Optional]": "[warning|critical]", + "name [Optional]": " [string]", + "lookback_period [Optional]": " [int|float]", + "subsequent_alert_wait_time [Optional]": " [int|float]", + "enabled [Optional]": " [bool]" +} +``` + + +### Alert Notifications + +An Alert Notification is a way for Arthur to communicate the occurance of an alert to users. A specific Alert Notification Configuration determines if and where a notification should be sent when an alert +on a specific model is triggered. + +Arthur currently supports 3 types of alert notifications: +* email +* PagerDuty +* ServiceNow + +(alert_notification_payload)= +#### What is included in an Alert Notification? + +An Alert Notification contains the following information: +* The model's display name +* The alert's priority level (warning or critical) +* The timestamp of when the alert was triggered +* A short description of the alert which includes: + * The metric name + * The batch id or time range for which the metric was evaluated + * The metric value that triggered the alert + * The threshold + +Here is an example alert notification sent via email: +![.png image](/_static/images/emailAlert.png) + +(create_alert_notification_configuration)= +#### Create Alert Notification Configuration + +To create an alert notification configuration, you can send a POST request to `/alert_notification_configurations`. + +* `user_id` - UUID of the user this alert notification configuration belongs to. Only specify if type is `"email"`. +* `model_id` - UUID of the model this alert notification configuration belongs to. +* `type` - Type of notification to send, currently the only supported values are `"email"`, `"PagerDuty"`, and + `"ServiceNow"`. +* `destination` - The email address to send the notification to. +>* If `type` is `"email"`, `destination` must match the email address associated with the above specified user id's + Arthur account. +>* If `type` is `"PagerDuty"`, `destination` should be the PagerDuty provided integration email address. Please see our {ref}`PagerDuty Integration Guide ` for more details. +>* If `type` is `"ServiceNow"`, `destination` should be the email address configured for integration with your ServiceNow instance. Please see our {ref}`ServiceNow Integration Guide ` for more details. +* `enabled` - Whether or not the notification configuration is enabled. Defaults to true. + +Query Request: +```json +{ + "user_id" : " [string]" , + "model_id" : " [string]", + "type" : "[email]", + "destination" : " [string]", + "enabled" : " [bool]" +} +``` + +Users can create configurations for themselves or must have at least a role of "Administrator" to create configurations +that are not associated with their user id. + + +#### Get Alert Notification Configuration + +The GET endpoint returns a paginated list of alert notification configurations and includes query parameters, +as `/alert_notification_configurations?model_id={model_id}&user_id{user_id}&page_size={page_size}&page={page}`. + +With a specific configuration ID handy, you can also send a GET request to `/alert_notification_configurations/{configuration_id}`. + + +#### Update Alert Notification Configuration + +With the specific configuration ID handy, you can send a PATCH request to `/alert_notification_configurations/{configuration_id}`. + +The fields supported for update are: +* `enabled` - Whether or not the notification configuration is enabled. If enabled, the destination address will be + auto-notified when an alert is triggered. + +Query Request: +```json +{ + "enabled" : " [bool]" +} +``` \ No newline at end of file diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/cv_onboarding.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/cv_onboarding.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..a203ce4d6a370211c8039e77276c9ad0a3ae65ca --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/cv_onboarding.md.txt @@ -0,0 +1,129 @@ +# CV Onboarding + +This page shows the basics of setting up computer vision (CV) models and onboarding to the Arthur system to monitor +vision-specific performance. + +## Getting Started + +The first step is to import functions from the `arthurai` package and establish a connection with Arthur. + +```python +# Arthur imports +from arthurai import ArthurAI +from arthurai.common.constants import InputType, OutputType, Stage + +arthur = ArthurAI(url="https://app.arthur.ai", + login="") +``` + +## Registering a CV Model + +Each computer vision model is created with `input_type = InputType.Image` and with specified width and height +dimensions for the processed images. Here, we register a classification model on 1024x1024 images: + +```python +arthur_cv_model = arthur.model(name="ImageQuickstart", + input_type=InputType.Image, + model_type=OutputType.Multiclass, + pixel_height=1024, + pixel_width=1024) +``` + +```{note} You can send images to the Arthur platform with any dimensions, and we'll keep the original you send as well +as a resized copy in the model dimensions. If you enable explainability for your model, the resized versions will be +passed to it to generate explanations. +``` + +The different `OutputType` values currently supported for computer vision models are classification, regression, and +object detection. + +## Formatting Data + +Computer vision models require the same structure as Tabular and NLP models. However, the attribute value for `Image` +attributes should be a valid path to the image file for that inference. + +Here is an example of a valid `reference_data` dataframe to build an ArthurModel with: + +```python + image_attr pred_value ground_truth non_input_1 +0 'img_path/img_0.png' 0.1 0 0.2 +1 'img_path/img_1.png' 0.05 0 -0.3 +2 'img_path/img_2.png' 0.02 1 0.7 ... +3 'img_path/img_3.png' 0.8 1 1.2 +4 'img_path/img_4.png' 0.4 0 -0.5 + ... +``` + +### Non-Input Attributes + +Any non-pixel features to be tracked in images for performance comparison or bias detection should be added as +non-input attributes. For example, any metadata about the identities of people captured in images for a CV model should +be included as non-input attributes. + +### Reviewing the Model Schema + +Before you call `arthur_model.save()`, you can call `arthur_model.review()` the model schema to check that your data is +parsed correctly. + +For an image model, the model schema should look like this: + +```python + name stage value_type categorical is_unique +0 image_attr PIPELINE_INPUT IMAGE False True +1 pred_value PREDICTED_VALUE FLOAT False False ... +2 ground_truth GROUND_TRUTH INTEGER True False +3 non_input_1 NON_INPUT_DATA FLOAT False False + ... +``` + +## Object Detection + +### Formatting Bounding Boxes + +If using an Object Detection model, bounding boxes should be formatted as lists in the form: + +`[class_id, confidence, top_left_x, top_left_y, width, height]` + +The first two components of the bounding box list represent the classification being made within the bounding box. The +`class_id` represents the ID of the class detected within the bounding box, and the `confidence` represents the % +confidence the model has in this prediction (`0.0` for completely unconfident and `1.0` for completely confident). + +The next four components of the bounding box list represent the location of the bounding box within the image: the +`top_left_x` and `top_left_y` represent the X and Y pixel coordinates of the top-left corner of the bounding box. These pixel coordinates are calculated from the origin, which is in the top left corner of the image. This means that each coordinate is calculated by counting pixels from the left of the image or the top of the image, respectively. The `width` represents the number of pixels the bounding box covers from left to right, and the `height` represents the number of pixels the bounding box covers from top to bottom. + +So using the following model schema as an example: + +```python + name stage value_type +0 image_attr PIPELINE_INPUT IMAGE +1 label GROUND_TRUTH BOUNDING_BOX +2 objects_detected PREDICTED_VALUE BOUNDING_BOX +``` + +a valid dataset would look like + +```python +# image_attr objects_detected ground_truth non_input_1 +0, 'img_path/img_0.png', [[0, 0.98, 12, 20, 50, 25], [0, 1, 14, 22, 48, 29], 0.2 + [1, 0.47, 92, 140, 80, 36]] +1, 'img_path/img_1.png', [[1, 0.22, 4, 5, 14, 32]] [1, 1, 25, 43, 49, 25] -0.3 #... +# ... +``` + +## Finishing Onboarding + +Once you have finished formatting your reference data and your model schema looks correct using `arthur_model.review()`, +you are finished locally configuring your model and its attributes - so you are ready to complete onboarding your model. + +To finish onboarding your CV model, the following steps apply, which is the same for CV models as it is for models +of any `InputType` and `OutputType`: + +```{include} finishing_onboarding.md +``` + +## Enrichments + +For an overview of configuring enrichments for image models, see the {doc}`enrichments guide `. + +For a step-by-step walkthrough of setting up the explainability Enrichment for image models, see +{ref}`cv_explainability`. diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/finishing_onboarding.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/finishing_onboarding.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..efe55d5f710a72a0fcfbafc1c317ce1d5d9426dd --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/finishing_onboarding.md.txt @@ -0,0 +1,13 @@ +--- +orphan: true +--- + +1. Save your model +2. Send inferences your model has made on historical data + 1. To confirm that the inferences have been sent, you can view your model and its inferences in the Arthur dashboard. +3. Connect your production data and model inference pipeline to Arthur + +To see an example of saving your model and sending inference data, see the {doc}`/user-guide/arthur_quickstart`. + +To see multiple examples of connecting production data and model inference pipeline to Arthur, see our +{doc}`/user-guide/integrations/index`. diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/index.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/index.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..563cde9452dd4ab09747797c6e431b5b9b69c976 --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/index.md.txt @@ -0,0 +1,593 @@ +# Model Onboarding + +### Overview + +This guide walks through the steps of onboarding a model deployed in production to Arthur. +Once your deployed model is onboarded, you can use Arthur to retrieve insights about +model performance efficiently and at scale. + +```{note} This walkthrough uses tabular data. + +To onboard models of other input types, see {doc}`cv_onboarding` and {doc}`nlp_onboarding`. +``` + +### Requirements + +You will need to have access to the data your model ingests and the predictions it produces. + +The model object itself is _not_ required, but it can be uploaded to enable the explainability enrichment. +See our {doc}`/more-info/FAQs` for more info. + +*** + +### Outline + +This guide will cover the three main steps to onboarding a model to the Arthur platform: + +- [Model Registration](#model-registration) is the process of registering the model schema with Arthur and sending reference data +- [Onboarding Existing Inferences](#onboard-existing-inferences) sends your model's historical predictions to the Arthur platform +- [Production Integration](#production-integration) connects your model's ongoing predictions in deployment to be logged with Arthur + + +*** + +## Model Registration + +### Connect to Arthur + +The first step is to import functions from the `arthurai` package and establish a connection with an Arthur username and password. + +```python +# Arthur imports +from arthurai import ArthurAI +from arthurai.common.constants import InputType, OutputType, Stage, ValueType, Enrichment + +arthur = ArthurAI(url="https://app.arthur.ai", + login="") +``` + +### Register Model Type + +To register a model, we start by creating a model object and defining its +{ref}`high-level metadata `: + +```python +arthur_model = arthur.model( + partner_model_id="OnboardingModel_123", + display_name="OnboardingModel", + input_type=InputType.Tabular, + output_type=OutputType.Multiclass, + is_batch=False) +``` + +In particular, we set `is_batch=False` to define this as a {ref}`streaming model `, +which means the Arthur platform will receive the model's inferences as they are produced live in deployment. + +### Register Attributes with [ArthurModel.build()](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.build) + +Next we'll add more detail to the model metadata, defining the model's {ref}`attributes `. +The simplest method of registering your attributes is to use +[ArthurModel.build()](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.build) +, which parses a Pandas DataFrame of your {ref}`reference dataset ` containing inputs, +metadata, predictions, and ground truth labels. In addition, a `pred_to_ground_truth_map` is required, which tells +Arthur which of your attributes represent to your model's predicted values, and how those predicted attributes correspond +to your model's ground truth attributes. + +Here we build a model with a `pred_to_ground_truth_map` configured for a binary classification model. +```python +# Map PredictedValue attribute to its corresponding GroundTruth attribute value. +# This tells Arthur that in the data you send to the platform, +# the `predicted_probability` column represents +# the probability that the ground-truth column has the value 1 +pred_to_ground_truth_map = { + 'predicted_probability' : 1 +} +arthur_model.build( + reference_df, + ground_truth_column='ground_truth_label', + pred_to_ground_truth_map=pred_to_ground_truth_map) +``` + +#### Non Input Attributes + +Some features of your data may be important to track for monitoring model performance even though they are not model +inputs or outputs. These features can be added as non input attributes in the ArthurModel: + +```python +# Specifying additional non input attributes when building a model. +# This tells Arthur to monitor ['age','sex','race','education'] +# in the reference and inference data you send to the platform +arthur_model.build( + reference_df, + ground_truth_column='ground_truth_label', + pred_to_ground_truth_map=pred_to_ground_truth_map, + non_input_columns=['age','sex','race','education'] +) +``` + +### Register Attributes Manually + +As an alternative to passing a DataFrame to +[ArthurModel.build()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.build) +, attributes can also be registered for your model +manually. Registering attributes manually may be preferable if you don't use the Pandas library, or if there are attribute +properties not configurable from parsing your reference data alone. + +[ArthurModel.add_attribute()](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.add_attribute) + is the generic method add any type of attribute to a model - its +[docstring](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.add_attribute) + also links to the additional attribute registration methods tailored to specific model and data types for convenience. + +#### Binary Classifier with Two Ground Truth Classes + +If the data you send to the platform for a binary classifier has columns for the predicted +probability and ground-truth-status of class 0, as well as columns for the predicted +probability and ground-truth-status of class 1, then map each predicted value column to its corresponding ground truth +column: + +```python +# Map PredictedValue attributes to their corresponding GroundTruth attribute names +pred_to_ground_truth_map = {'pred_0' : 'gt_0', + 'pred_1' : 'gt_1'} + +# add the ground truth and predicted attributes to the model +# specifying that the `pred_1` attribute is the +# positive predicted attribute, which means it corresponds to the +# probability that the binary target attribute is 1 +arthur_model.add_binary_classifier_output_attributes( + positive_predicted_attr='pred_1', + pred_to_ground_truth_map=pred_to_ground_truth_map) + +``` + +#### More Than Two Ground Truth Classes + +If you are using a Multi-class model then you will have more than two Ground Truth classes. In order to make this work with the Arthur Platform, you will need to: + +1. Ensure that you are using `predict_proba` (or a similar function) to predict the probability of a specific Ground Truth Class +2. Ensure that each class probability is included in its own column in your dataset +3. Ensure that your Ground Truth mapping contains all possible classes that might be predicted + +So for example, if your model identifies the presence of an animal, specifically a dog, cat, or horse, in an image, your Ground Truth mapping must contain items for each of these clasess (even if the model output doesn't predict a value for these categories). + +If the data you send to the platform has ground truth one-hot encoded, then map predictions to each column name: + +```python +# Map PredictedValue attributes to their corresponding GroundTruth attribute names. +# This pred_to_ground_truth_map maps predicted values to one-hot encoded ground truth columns. +# For example, this tells Arthur that the `probability_dog` column represents +# the probability that the `dog_ground_truth` column has the value 1. +pred_to_ground_truth_map = { + "probability_dog": "dog_ground_truth", + "probability_cat": "cat_ground_truth", + "probability_horse": "horse_ground_truth" +} + +arthur_model.add_multiclass_classifier_output_attributes( + pred_to_ground_truth_map=pred_to_ground_truth_map +) +``` + +If the data you send to the platform has ground truth values in a single column, then map predictions to each column value: + +```python +# Map PredictedValue attributes to their corresponding GroundTruth attribute values. +# This pred_to_ground_truth_map maps predicted values to the values of the ground truth column. +# For example, this tells Arthur that the `probability_dog` column represents +# the probability that the ground truth column has the value "dog". +pred_to_ground_truth_map = { + "probability_dog": "dog", + "probability_cat": "cat", + "probability_horse": "horse" +} + +arthur_model.add_classifier_output_attributes_gtclass( + pred_to_ground_truth_map=pred_to_ground_truth_map, + ground_truth_column="animal" +) +``` + +#### Regression Attributes + +If you are registering a regression model, then specify the type of the predicted and ground truth values when registering +the attributes: + +```python +# Map PredictedValue attribute to its corresponding GroundTruth attribute +pred_to_ground_truth_map = { + "predidcted_value": "ground_truth_value", +} + +# add the pred_to_ground_truth_map, and specify the type of the +# predicted and ground truth values +arthur_model.add_regression_output_attributes( + pred_to_ground_truth_map = pred_to_ground_truth_map, + value_type = ValueType.Float +) +``` + +### Set Reference Data + +If you used your reference data to register your model's attributes with +[ArthurModel.build()](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.build) +, you don't need to complete this step because the dataframe you pass in as input to `build()` will be automatically saved +as your model's reference data in the Arthur system. + +If you didn't use `build()` or want to update the reference dataset to be sent to Arthur, you can set it directly by using the +[`ArthurModel.set_reference_data()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.set_reference_data) +method. This is also necessary if your reference dataset is too large to fit into memory as a Pandas DataFrame. + + +### Review Model + +The method +[ArthurModel.review()](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html#arthurai.core.models.ArthurModel.review) +returns the model schema, which is a dataframe of properties for each of your model's registered attributes. The `review()` +method is automatically called when using `build()`, and can also be called on its own. Inspecting the model schema `review()` +returns is recommended to verify that attribute properties have been inferred correctly. +```{note} +Some important properties to check in the model schema: + +- Check that attributes have the correct value types + +- Check that attributes are correctly marked as categorical or continuous + +- Check that attributes you want to monitor for bias have monitor_for_bias=True +``` + +By default, printing the model schema doesn't display all the attribute properties. +Therefore if you want to examine the model schema in its entirety, you can do so by formatting the maximum number of +rows and columns to display: + +```python +pd.set_option('display.max_columns', 10); pd.set_option('max_rows', 50) +arthur_model.review() +``` + +The model schema should look like this: + +```python + name stage value_type categorical is_unique categories bins range monitor_for_bias +0 X0 PIPELINE_INPUT FLOAT False False [] None [16.0, 58.0] False +1 ground_truth_label GROUND_TRUTH INTEGER True False [{value: 0}, {value: 1}] None [None, None] False +2 predicted_probability PREDICTED_VALUE FLOAT False False [] None [0, 1] False +``` + +```{note} + +To modify attribute properties in the model schema table, see the docstring for +[ArthurAttribute](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.attributes.ArthurAttribute.html#arthurai.core.attributes.ArthurAttribute) + for a complete description of model attribute properties and their configuration methods. +``` + + +### Save Model + +Once you have reviewed your model schema and made any necessary modification to your model's attributes, you are ready +to save your model to Arthur. + +Calling `arthur_model.save()` returns the unique ID Arthur creates for your model. You can easily load the model from +the Arthur system later on using either this ID or the `partner_model_id` you specified when you first created the model. +```python +arthur_model_id = arthur_model.save() +``` + +### Activate Enrichments + +[Enrichments](../basic_concepts.html#enrichments) are model monitoring services Arthur provides that can be activated +once your model is saved to Arthur. + +Models will have the {ref}`Anomaly Detection ` enabled by default if your plan supports +it, but first we'll enable {ref}`Hotspots ` which doesn't require any configuration. + +Second, we activate explainability, which requires more configuration and therefore comes with its own helper function. + +```python +# first activate hotspots +arthur_model.enable_hotspots() + +# enable explainability using its own helper function for convenience +arthur_model.enable_explainability( + df=X_train, + project_directory="/path/to/model_folder/", + requirements_file="requirements.txt", + user_predict_function_import_path="model_entrypoint", + ignore_dirs=["folder_to_ignore"] # optionally exclude directories within the project folder from being bundled with predict function +) +``` + +For more information on enabling enrichments and updating their configurations, see {doc}`/user-guide/walkthroughs/enrichments`. + +*** + +## Onboarding Existing Inferences + +If your model is already running in production, a good next step is to send your historical inferences to Arthur. In +this section, we'll gather those historical inferences and then send them to the platform. + + +### Collecting Historical Inferences + +When logging inferences with Arthur, you may include: +- **Model Inputs** which were sent to your model to make predictions +- **Model Predictions** which you could fetch from storage or re-compute from your input data if you don't have them +saved +- **Non-Input Data** that you want to include, and you registered with your Arthur model but doesn't feed +into your model +- **Ground Truth** labels for the inputs if you have them available +- **Partner Inference IDs** that uniquely identify your predictions and can be used to update inferences with ground +truth labels in the future (details below) +- **Inference Timestamps** that you can approximate with the [`generate_timestamps()` function](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.util.generate_timestamps.html?highlight=generate_timestamps#arthurai.util.generate_timestamps) +if you're just simulating production data or omit to use the current time +- **Ground Truth Timestamps** that you can approximate with the [`generate_timestamps()` function](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.util.generate_timestamps.html?highlight=generate_timestamps#arthurai.util.generate_timestamps) +if you're just simulating production data or omit to use the current time +- **Batch IDs** that denote something like a unique "run ID" if your model is a batch model + +You might have all the data you need in one convenient place, or more often you'll need to gather them from a couple of +tables or data stores. For example, you might: +- collect your input and non-input data from your data warehouse +- fetch your predictions and timestamps from blob storage used with your model deployment +- match them to your ground truth labels in a different legacy system + +#### Partner Inference IDs + +Arthur offers Partner Inference IDs as a way to match specific inferences in Arthur against your other systems and +update your inferences with ground truth labels as they become available in the future. The most appropriate choice +for a partner inference ID depends on your specific circumstances but common strategies include _using existing IDs_ +and _joining metadata with non-unique IDs_. + +If you already have existing IDs that are unique to each inference and easily attached to future ground truth labels, +you can simply use those (casting to strings if needed). + +Another common approach is to construct a partner inference ID from multiple pieces of metadata. For example, if your +model makes predictions about your customers at most once per day, you might construct your partner inference IDs as +`{customer_id}-{date}`. This would be easy to reconstruct when sending ground truth labels much later: simply lookup +the labels for all the customers passed to the model on a given day and append that date to their ID. + +If you don't supply partner inference IDs, the SDK will generate them for you and return them to your +`send_inferences()` call. These can be kept for future reference, or discarded if you've already sent ground truth +values or don't plan to in the future. + +### Sending Inferences + +Arthur offers many flexible options for sending your inferences. We have a few SDK methods can accept Pandas DataFrames, +native Python objects, and Parquet files — with data grouped into single datasets or spread across separate method calls +and parameters. Two examples of these are outlined below, but for all the available usages see our SDK Reference for: + +- the [`ArthurModel.send_inference()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html?highlight=send_inferences#arthurai.core.models.ArthurModel.send_inferences) and [`update_inference_ground_truths()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html?highlight=update_inference_ground_truths#arthurai.core.models.ArthurModel.update_inference_ground_truths) methods, +which are recommended for non-Parquet datasets under 100,000 rows +- the [`ArthurModel.send_bulk_inferences()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html?highlight=send_bulk_inferences#arthurai.core.models.ArthurModel.send_bulk_inferences) and [`send_bulk_ground_truths()`](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.core.models.ArthurModel.html?highlight=send_bulk_ground_truths#arthurai.core.models.ArthurModel.send_bulk_ground_truths) +methods which are recommended for sending large datasets or Parquet files + +If you'd prefer to send data directly the REST API, see the [Inferences section of our API Reference](https://docs.arthur.ai/api-documentation/v3-api-docs.html#tag/inferences). + +#### A Simple Case + +Here we suppose we've gathered our input, non-input, and ground truth labels into a single DataFrame. We also fetch +our predictions and the time at which they were made, and send everything in a single method call. Here we're passing +the predictions and timestamps as parameters into the method, but we could also simply add them to the `inference_data` +DataFrame. We don't worry about partner inference IDs here, leaving them to be auto-generated. + +```python +# load model input and non-input values, and ground truth labels + timestamps as a Pandas DataFrame +inference_data = ... + +# retrieve predictions and timestamps as lists +# note that we could also include these as columns in the DataFrame above +predictions, inference_timestamps = ... + +# Send the inferences to Arthur +# just using auto-generated partner inference IDs since we're sending ground truth right now +arthur_model.send_inferences( + inference_data, + predictions=predictions, + inference_timestamps=inference_timestamps) +``` + +### Sending Inferences at Scale with Delayed Ground Truth + +Next, we consider a more complex case where we have a batch model with many inferences and send the ground truth +separately, relying on our Partner Inference IDs to join the ground truth values to the previous inferences. We +assume the data is neatly collected as described above. This may rely on an [ETL job](https://en.wikipedia.org/wiki/Extract,_transform,_load) +that might involve a Spark job or a Redshift export or a Snowflake export or Apache Beam job in Google Cloud Dataflow +or Pandas `from_sql()` and `to_parquet()` calls or whatever data wrangling toolkit you're most comfortable with. + +```python +# we can collect a set of folder names each corresponding to a batch run, containing one or +# more Parquet files with the input attributes columns, non-input attribute columns, and +# prediction attribute columns as well as a "partner_inference_id" column with our unique +# identifiers and an "inference_timestamp" column +inference_batch_dirs = ... + +# then suppose we have a directory with one or more parquet files containing matching +# "partner_inference_id"s and our ground truth attribute columns as well as a +# "ground_truth_timestamp" column +ground_truth_dir = ... + +# send the inferences to Arthur +for batch_dir in inference_batch_dirs: + batch_id = batch_dir.split("/")[-1] # use the directory name as the Batch ID + arthur_model.send_bulk_inferences( + directory_path=batch_dir, + batch_id=batch_id) + +# send the ground truths to Arthur +arthur_model.send_bulk_ground_truths(directory_path=ground_truth_dir) +``` + + +### See Model in Dashboard +To confirm that the inferences have been sent, you can view your model and its inferences in the Arthur dashboard. + +### Performance Results + +Once you've logged your model's inferences with Arthur you can evaluate your model performance. You can open your +Arthur dashboard to view model performance in the UI, or use the code snippets below to fetch the same results right +from your Python environment using {doc}`Arthur's Query API `. + +#### Query Overall Performance + +You can query overall Accuracy Rate with the following snippet, but for non-classifier models you might consider +replacing the `accuracyRate` function with another {doc}`model evaluation function `. + +```python +# query model accuracy across the batches +query = { + "select": [ + { + "function": "accuracyRate" + } + ] +} +query_result = arthur_model.query(query) +``` + +#### Visualize Performance Results + +Visualize performance metrics over time: + +```python +# plot model performance metrics over time +arthur_model.viz.metric_series( + ["auc", "falsePositiveRate"], + time_resolution="hour") +``` + +Visualize data drift over time: + +```python +# plot drift over time of attributes +# from their baseline distribution in the model's reference data +arthur_model.viz.drift_series( + ["X0", "predicted_probability"], + drift_metric="KLDivergence", + time_resolution="hour") +``` + +#### {doc}`API Query Guide ` + +For more analysis of model performance, the {doc}`/user-guide/api-query-guide/index` shows how to use the Arthur +API to get the model performance results you need, efficiently and at scale. Our backend query engine allows for fine-grained and +customizable performance analysis. + +*** + +## Production Integration + +Now that you have registered your model and successfully gotten initial performance metrics on your model's +historical inferences, you are ready to connect your production pipeline to Arthur. + +Arthur has several methods of receiving your production model's inference data. Most involve some process making a +call to one of the SDK methods described above, but where that process runs and reads data from depends on your +production environment. We explore a few common patterns below, as well as some of Arthur's direct +{doc}`integrations `. + +For a quick start, consider the [quick integration](#quick-integration), which only involves adding a few lines of code +to your model prediction code. + +If your model inputs and predictions are written out to a data stream such as a Kafka topic, consider [adding a stream +listener](#streaming-integration) + +If you don't mind a bit of latency between when your predictions are made and logged with Arthur or it's much easier +to read your inference data from rest, consider setting up an [inference upload job](#inference-upload-job). + +Note that these methods can be combined for prediction and ground truth values: you might use the quick integration or +streaming approach for inference data but a batch job to update ground labels. + +### API Keys + +API Keys authorize your request to send and receive data to and from the Arthur platform. With a valid API key added +to your production environment, your model deployment code can be augmented to send your model's inferences to Arthur. +See the {doc}`/platform-management/access-control-overview/standard_access_control` to obtain an Arthur API key. + +### Quick Integration + +Quick integration with Arthur means using the `send_inferences()` method *when* and *where* your model object +produces inferences. This is the simplest and quickest way to connect a production model to Arthur. However, this option +would have you add some latency to the speed with which your model is generating inferences. For more efficient +approaches, see options 2 and 3. + +For example, suppose your model is hosted in production behind using an API using Flask - the call to +`arthur_model.send_inferences()` just needs to be included wherever your `predict` function is defined so your updated +code might look something like this: + +```python +#################################################### +# New code to fetch the ArthurModel +# connect to Arthur +import os +from arthurai import ArthurAI +arthur = ArthurAI( + url="https://app.arthur.ai", + access_key=os.environ["ARTHUR_API_KEY"]) + +# retrieve the arthur model +arthur_model = arthur.get_model(os.environ["ARTHUR_PARTNER_MODEL_ID"], id_type='partner_model_id') +#################################################### + +# your original model prediction function +# which can be on its own as a python script +# or wrapped by an API like a Flask app +def predict(): + # get data to apply model to + inference_data = ... + + # generate inferences + # in this example, the predictions are classification probabilities + predictions = model.predict_proba(...) + + #################################################### + #### NEW PART OF YOUR MODEL'S PREDICTION SCRIPT + + # SEND NEW INFERENCES TO ARTHUR + arthur_model.send_inferences( + inference_data, + predictions=predictions) + #################################################### + + return predictions +``` + +Alternatively if you have a batch model that runs in jobs, you might add similar code to the very end of your job, +rather than inside the `predict()` function. + +### Streaming Integrations + +If you write your model's inputs and outputs to a data stream, you can add a listener to that stream to log those +inferences with Arthur. For example, if you have a Kafka topic you might add a new `arthur` consumer group to listen +to new events and pass them to the `send_inferences()` method. If your inputs and predictions live in different topics +or you want to add non-input data from another topic, you might use [Kafka Streams](https://kafka.apache.org/documentation/streams/) +to join the various topics before sending to Arthur. + +### Inference Upload Jobs + +Another approach is to run jobs that read data from rest and send it to the Arthur platform. These jobs might be +scheduled or event-driven, depending on your architecture. + +For example, you might have regularly scheduled jobs that: + +1. look up the inference or ground truth data since the last run +1. format the data and write it to a few Parquet files +1. send the Parquet files to the Arthur platform using `send_bulk_inferences()` or `send_bulk_ground_truths()` + +### Integrations + +Rather than hand-rolling your own inference upload jobs, Arthur also offers more direct integrations. + +For example, our {ref}`SageMaker Data Capture Integration ` makes integrating with SageMaker +models a breeze by utilizing Data Capture to log the inferences into files in S3, and triggering upload jobs in +response to those file write events. + +Our {ref}`Batch Ingestion from S3 ` allows you to just upload your +Parquet files to S3, and Arthur will automatically import them into the system. + + +```{toctree} +:hidden: +:maxdepth: 3 + +General Onboarding +cv_onboarding +nlp_onboarding +``` + diff --git a/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/nlp_onboarding.md.txt b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/nlp_onboarding.md.txt new file mode 100644 index 0000000000000000000000000000000000000000..3a9f15a84e66922d3e1529af7f6a3e6f4adcf88e --- /dev/null +++ b/files/arthur-docs-markdown/user-guide/walkthroughs/model-onboarding/nlp_onboarding.md.txt @@ -0,0 +1,94 @@ +# NLP Onboarding + +This page walks through the basics of setting up a natural language processing (NLP) model and onboarding it to the +Arthur system to monitor language-specific performance. + +## Getting Started + +The first step is to import functions from the `arthurai` package and establish a connection with Arthur. + +```python +# Arthur imports +from arthurai import ArthurAI +from arthurai.common.constants import InputType, OutputType, Stage + +arthur = ArthurAI(url="https://app.arthur.ai", + login="") +``` + +## Registering an NLP Model + +Each NLP model is created with a name and with `input_type = InputType.NLP`. Here, we register a classification model +on text specifying a `text_delimiter` of `NOT_WORD`: + +```python +arthur_nlp_model = arthur.model(name="NLPQuickstart", + input_type=InputType.NLP, + model_type=OutputType.Multiclass, + text_delimiter=TextDelimiter.NOT_WORD) +``` + +The different `OutputType` values currently supported for NLP models are classification, multi-labeling, and regression. + +### Text Delimiter + +NLP models also require specifying a `text_delimiter`, which specifies how a raw document is split into tokens. + +A common choice for `text_delimiter` will be `TextDelimiter.NOT_WORD`, since that will ignore punctuation and tokenize +text based only on the words present. However, if punctuation and non-word text needs to be considered by your model, +you should consider using other options for a delimiter to ensure those other pieces of text are processed by your NLP +model. + +For a full list of available text delimiters with examples, see the +[TextDelimiter constant documentation](https://docs.arthur.ai/sdk/sdk_v3/apiref/arthurai.common.constants.TextDelimiter.html) +in our SDK reference. + +## Formatting Reference/Inference Data + +Column names can contain only alphanumeric and underscore characters. The rest of the string values can have +additional characters as raw text. + +```python + text_attr pred_value ground_truth non_input_1 +0 'Here-is some text' 0.1 0 0.2 +1 'saying a whole lot' 0.05 0 -0.3 +2 'of important things!' 0.02 1 0.7 +3 'With all kinds of chars?!' 0.2 0 0.1 ... +4 'But attribute/column names' 0.6 1 -0.6 +5 'can only use underscore.' 0.9 1 -0.9 + ... +``` + +### Reviewing the Model Schema + +Before you register your model with Arthur by calling `arthur_model.save()`, you can call `arthur_model.review()` the +model schema to check that your data is parsed correctly. + +For an NLP model, the model schema should look like this: + +```python + name stage value_type categorical is_unique +0 text_attr PIPELINE_INPUT UNSTRUCTURED_TEXT False True +1 pred_value PREDICTED_VALUE FLOAT False False ... +2 ground_truth GROUND_TRUTH INTEGER True False +3 non_input_1 NON_INPUT_DATA FLOAT False False + ... +``` + +## Finishing Onboarding + +Once you have finished formatting your reference data and your model schema looks correct using `arthur_model.review()`, +you are finished registering your model and its attributes - so you are ready to complete onboarding your model. + +To finish onboarding your NLP model, the following steps apply, which is the same for NLP models as it is for models +of any `InputType` and `OutputType`: + +```{include} finishing_onboarding.md +``` + +## Enrichments + +For an overview of configuring enrichments for NLP models, see the {doc}`/user-guide/walkthroughs/enrichments` guide. + +For a step-by-step walkthrough of setting up the explainability Enrichment for NLP models, see +{ref}`nlp_explainability`. diff --git a/files/vectorstores/.DS_Store b/files/vectorstores/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..5008ddfcf53c02e82d7eee2e57c38e5672ef89f6 Binary files /dev/null and b/files/vectorstores/.DS_Store differ diff --git a/files/vectorstores/arthur_vectorstore.pkl b/files/vectorstores/arthur_vectorstore.pkl new file mode 100644 index 0000000000000000000000000000000000000000..98e7068ea48e323a3dbc4e751444bf67913a0a05 --- /dev/null +++ b/files/vectorstores/arthur_vectorstore.pkl @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f48e27fbb868a6f6e54599797183284470462c53a47d5c5efdddcee7378bda8f +size 6836487