-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[TA] Healthcare Design update #18200
Merged
maririos
merged 12 commits into
Azure:master
from
suhas92:sumeh/update-healthcare-design
Feb 2, 2021
+2,302
−860
Merged
Changes from 5 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
2d8abda
initial changes tests passing
suhas92 0067984
added related healthcare entities
suhas92 7c143e9
updated session records
suhas92 952eb28
addressed comments
suhas92 9d456da
addressed comments
suhas92 2dba53e
revert sessio records
suhas92 2143fb7
addressee comments
suhas92 14ac143
added changelog
suhas92 a3eaf05
updated breaking changes
suhas92 dd348b9
update readme
suhas92 7bb1791
updated change log
suhas92 31daf0d
run scripts
suhas92 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
109 changes: 61 additions & 48 deletions
109
sdk/textanalytics/Azure.AI.TextAnalytics/api/Azure.AI.TextAnalytics.netstandard2.0.cs
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
49 changes: 49 additions & 0 deletions
49
sdk/textanalytics/Azure.AI.TextAnalytics/src/AnalyzeHealthcareEntitiesResult.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT License. | ||
|
||
using System; | ||
using System.Collections.Generic; | ||
using System.Collections.ObjectModel; | ||
using Azure.AI.TextAnalytics.Models; | ||
|
||
namespace Azure.AI.TextAnalytics | ||
{ | ||
/// <summary> | ||
/// DocumentHealthcareEntities. | ||
/// </summary> | ||
public partial class AnalyzeHealthcareEntitiesResult : TextAnalyticsResult | ||
{ | ||
private readonly IReadOnlyCollection<HealthcareEntity> _entities; | ||
|
||
internal AnalyzeHealthcareEntitiesResult(string id, TextDocumentStatistics statistics, | ||
IReadOnlyList<HealthcareEntity> healthcareEntities, | ||
IList<TextAnalyticsWarning> warnings) | ||
: base(id, statistics) | ||
{ | ||
_entities = healthcareEntities; | ||
maririos marked this conversation as resolved.
Show resolved
Hide resolved
|
||
Warnings = new ReadOnlyCollection<TextAnalyticsWarning>(warnings); | ||
} | ||
|
||
internal AnalyzeHealthcareEntitiesResult(string id, TextAnalyticsError error) : base(id, error) { } | ||
|
||
/// <summary> Warnings encountered while processing document. </summary> | ||
public IReadOnlyCollection<TextAnalyticsWarning> Warnings { get; } = new List<TextAnalyticsWarning>(); | ||
|
||
/// <summary> | ||
/// Gets the collection of healthcare entities in the document. | ||
/// </summary> | ||
public IReadOnlyCollection<HealthcareEntity> Entities | ||
{ | ||
get | ||
{ | ||
if (HasError) | ||
{ | ||
#pragma warning disable CA1065 // Do not raise exceptions in unexpected locations | ||
throw new InvalidOperationException($"Cannot access result for document {Id}, due to error {Error.ErrorCode}: {Error.Message}"); | ||
#pragma warning restore CA1065 // Do not raise exceptions in unexpected locations | ||
} | ||
return _entities; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are you thinking on having a separate PR to improve the docstrings?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure what should be the docstrings, are there any guidelines around it? can you provide some example doc strings?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sadly I don't think there are any guidelines for it, but think of it as the way to explain to a user what each class, property, method is about.
You could use the docstring in other endpoints or libraries as guidance
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i.e. is a user reads
The AnalyzeHealthcareEntitiesOperation class for LRO.
it actually doesn't mean anything for them. What isLRO
? and what is the purpose of this class?something like
Tracks the status of a long-running operation that analyze the healthcare entities from the given documents
. or something along those lines