Skip to content

Commit 6754479

Browse files
Merge pull request #3347 from Albertyang0/2025_03-Monthly-broken-links-fix-jboback
2025_03 - Fix monthly broken links - jboback
2 parents 8f3d178 + 8ef566f commit 6754479

File tree

1 file changed

+4
-6
lines changed
  • articles/ai-services/language-service/question-answering/includes

1 file changed

+4
-6
lines changed

articles/ai-services/language-service/question-answering/includes/sdk-python.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,10 @@ Use this quickstart for the custom question answering client library for Python
1313
* Get an answer from a body of text that you send along with your question.
1414
* Get the confidence score for the answer to your question.
1515

16-
[Reference documentation][questionanswering_refdocs] | [Package (PyPI)][questionanswering_pypi_package] | [Additional samples][questionanswering_samples] | [Library source code][questionanswering_client_src]
16+
[Package (PyPI)][questionanswering_pypi_package] | [Additional samples][questionanswering_samples] | [Library source code][questionanswering_client_src]
1717

18-
[questionanswering_client_class]: https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.html#azure.ai.language.questionanswering.QuestionAnsweringClient
1918
[questionanswering_client_src]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/cognitivelanguage/azure-ai-language-questionanswering/
2019
[questionanswering_pypi_package]: https://pypi.org/project/azure-ai-language-questionanswering/
21-
[questionanswering_refdocs]: https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.html
2220
[questionanswering_samples]: https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/cognitivelanguage/azure-ai-language-questionanswering/samples/README.md
2321

2422
## Prerequisites
@@ -48,7 +46,7 @@ pip install azure-ai-language-questionanswering
4846

4947
### Generate an answer from a project
5048

51-
The example below will allow you to query a project using [get_answers](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.html#azure.ai.language.questionanswering.QuestionAnsweringClient.get-answers) to get an answer to your question. You can copy this code into a dedicated .py file or into a cell in [Jupyter Notebook/Lab](https://jupyter.org/).
49+
The example below will allow you to query a project using get_answers to get an answer to your question. You can copy this code into a dedicated .py file or into a cell in [Jupyter Notebook/Lab](https://jupyter.org/).
5250

5351
You need to update the code below and provide your own values for the following variables.
5452

@@ -137,7 +135,7 @@ Confidence Score: 0.0
137135

138136
## Query text without a project
139137

140-
You can also use custom question answering without a project with [get_answers_from_text](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.html#azure.ai.language.questionanswering.QuestionAnsweringClient.get-answers-from-text). In this case, you provide custom question answering with both a question and the associated text records you would like to search for an answer at the time the request is sent.
138+
You can also use custom question answering without a project with get_answers_from_text. In this case, you provide custom question answering with both a question and the associated text records you would like to search for an answer at the time the request is sent.
141139

142140
For this example, you only need to modify the variables for `endpoint` and `credential`.
143141

@@ -184,5 +182,5 @@ A: Power and charging. It takes two to four hours to charge the Surface Pro 4 ba
184182
Confidence Score: 0.9254655838012695
185183
```
186184

187-
In this case, we iterate through all responses and only return the response with the highest confidence score that is greater than 0.9. To understand more about the options available with [get_answers_from_text](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.html#azure.ai.language.questionanswering.QuestionAnsweringClient.get-answers-from-text), review the [AnswersFromTextOptions parameters](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.models.html#azure.ai.language.questionanswering.models.AnswersFromTextOptions).
185+
In this case, we iterate through all responses and only return the response with the highest confidence score that is greater than 0.9. To understand more about the options available with get_answers_from_text, review the [AnswersFromTextOptions parameters](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-ai-language-questionanswering/1.0.0/azure.ai.language.questionanswering.models.html#azure.ai.language.questionanswering.models.AnswersFromTextOptions).
188186

0 commit comments

Comments
 (0)