82 Commits

Author SHA1 Message Date
Billy Hu 9345ad323a Fix Build Doc CI issues (#3783)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution
guidelines](https://github.com/microsoft/promptflow/blob/main/CONTRIBUTING.md).**
- [ ] **I confirm that all new dependencies are compatible with the MIT
license.**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-10-31 14:12:30 -07:00
Hanchi Wang e79da2e20a Remove tracing from navigation and experimental label from pf CLI (#3730)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution
guidelines](https://github.com/microsoft/promptflow/blob/main/CONTRIBUTING.md).**
- [x] **I confirm that all new dependencies are compatible with the MIT
license.**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-09-13 01:00:51 -07:00
jingyizhu99 6e1d23d5f6 Update documents to include rerank tool (#3691)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution
guidelines](https://github.com/microsoft/promptflow/blob/main/CONTRIBUTING.md).**
- [x] **I confirm that all new dependencies are compatible with the MIT
license.**
- [x] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-09-03 11:49:11 -07:00
Brynn Yin 027dbd9e11 Fix broken doc link (#3653)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution
guidelines](https://github.com/microsoft/promptflow/blob/main/CONTRIBUTING.md).**
- [ ] **I confirm that all new dependencies are compatible with the MIT
license.**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

Signed-off-by: Brynn Yin <biyi@microsoft.com>
2024-08-14 14:57:39 +08:00
Cheng Liu e0a60ef2a3 Update External Link Reference in trace-span-spec-reference.md (#3415)
# Description

This pull request updates an external link reference within a
`trace-span-spec-reference.md` to ensure accuracy and relevance of the
documentation. The modification corrects the hyperlink to point to the
intended web resource.

# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.
2024-06-14 12:47:45 +08:00
ChenJieting 71b308bbc8 update the link for MaaS deployment guidance (#3324)
# Description
Update links that related to the cloud documentation updates for several
pages.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.
2024-05-22 11:20:41 +08:00
Cheng Liu 8393665023 Refinement of Trace Span Specification Documentation (#3266)
# Description

This PR introduces enhancements to the Markdown file detailing the trace
span specification. Key changes include the addition of punctuation at
the end of sentences for improved readability and the elevation of
previously bolded text to higher-level titles for better document
structure. These updates aim to provide clearer and more accessible
documentation for contributors.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Zhidong Zhu <zhuzhidong@gmail.com>
2024-05-16 14:10:38 +08:00
nick863 0faa7cfae4 Add the sphinx docbuild for promptflow-evals. (#3257)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues. See work item 3207080.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [x] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.
2024-05-15 10:56:42 -07:00
Philip Gao 874bd59f16 Wording Change: automatic runtime to compute session (#3064)
# Description

automatic runtime to compute session

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-05-14 14:49:14 +08:00
Cheng Liu d4c4a86f4d [tracing][doc] PromptFlow Span Specifications (#3020)
# Description

This pull request introduces a update to the PromptFlow span
documentation. The doc include refined explanations of the span types,
standardized formatting for attributes and events, and the addition of a
conclusion section that emphasizes the importance of adhering to the
tracing specifications for system transparency and consistency.

# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.
2024-05-13 19:48:51 +08:00
Xiaopeng Wang dbd9b42aef support serving engine switch in pf serve cmd (#3161)
# Description

Add --engine parameter in `pf flow serve` command, customer can use this
parameter to switch the python serving engine between `flask` and
`fastapi`, it's default to `flask`

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: xiaopwan <xiaopwan@microsoft.com>
2024-05-11 16:57:13 +08:00
Zhengfei Wang 873d29fa89 [doc][trace] Add page for trace local to cloud (#3178)
# Description

- Add page for trace local to cloud
- Add `pf flow test ... --collection <collection>` in CLI reference doc

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.
2024-05-10 17:10:23 +08:00
Yao 0ed212e93b Refine openai native error message with invalid tool calls (#3130)
# Description

Related [Task
3146129](https://msdata.visualstudio.com/Vienna/_workitems/edit/3146129)
: Refine openai native error message "Invalid parameter: messages with
role 'tool' must be a response to a preceeding message with
'tool_calls'." by adding TSG


Test:
1. Missing correct 'tool_calls' under assistant role:

![image](https://github.com/microsoft/promptflow/assets/46446115/b5f47f7f-df02-4f75-bb55-e3b85342ad4f)
**Original error message**:

![image](https://github.com/microsoft/promptflow/assets/46446115/c3d07913-ab17-44db-82e2-5201e9e3034f)

**Refined error message**:

![image](https://github.com/microsoft/promptflow/assets/46446115/7b09a903-4024-4246-9d8e-04e96910b5f1)

2. Missing role 'tool' after assitant tools_calls message:

![image](https://github.com/microsoft/promptflow/assets/46446115/0f644155-de58-49b7-8611-1428db6e3f20)
**Original error message**:

![image](https://github.com/microsoft/promptflow/assets/46446115/a9da8202-c05b-4a9b-a548-5e0207f1a8ac)

**Refined error message**:

![image](https://github.com/microsoft/promptflow/assets/46446115/13230945-6d1d-498e-944a-c0f3edd70ed8)



# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.

---------

Co-authored-by: yalu4 <yalu4@microsoft.com>
2024-05-09 15:27:05 +08:00
jingyizhu99 602e48493d Generate reference docs for azureml-rag (#3157)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
Co-authored-by: Brynn Yin <biyi@microsoft.com>
2024-05-09 13:26:03 +08:00
Zhengfei Wang b5ad5f69fd [doc] Add pf trace delete in CLI command reference doc (#3025)
# Description

Add CLI reference doc for `pf trace delete`.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-04-26 11:55:10 +08:00
Ge Gao 4560eea6bf Update llm-tool.md and concept-connections.md to include Serverless Connection (#2959)
# Description
Update llm-tool.md and concept-connections.md to include Serverless
Connection

---------

Co-authored-by: Ge Gao <gega@microsoft.com>
2024-04-26 11:02:24 +08:00
Ying Chen e1aecc2b1c Add how-to-guide doc for flow test --ui (#2868)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

![image](https://github.com/microsoft/promptflow/assets/26239730/82fba006-709f-46e5-86e0-3d31c27952ec)

![image](https://github.com/microsoft/promptflow/assets/26239730/f48313a8-8f21-4ad3-ab54-ab5331382ad7)

![image](https://github.com/microsoft/promptflow/assets/26239730/acbb748c-e75a-453e-9c0b-2b76b8b031b9)


# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Ying Chen <2601502859@qq.com>
2024-04-23 18:47:03 +08:00
Ying Chen c2e8e33a30 [PFS] Make pfs try start with fixed port. (#2830)
# Description

Start: always start from a fixed port
      While port is used:
            Port +=1
      Dump port to port file

![image](https://github.com/microsoft/promptflow/assets/26239730/07b35d95-72df-4daf-8461-2a6d380fd044)

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Ying Chen <2601502859@qq.com>
2024-04-23 11:25:25 +08:00
zhen 557b8c1493 [prompty] prompty support sample file as input (#2849)
# Description
- json file as sample input
```
---
name: Basic Prompt
description: A basic prompt that uses the GPT-3 chat API to answer questions
model:
    api: chat
    configuration:
      type: azure_openai
      azure_deployment: gpt-35-turbo
      connection: azure_open_ai_connection
    parameters:
      max_tokens: 128
      temperature: 0.2
inputs:
  firstName:
    type: string
    default: John
  lastName:
    type: string
    default: Doh
  question:
    type: string
sample: path/to/inputs.json
---
system:
You are an AI assistant who helps people find information.
As the assistant, you answer questions briefly, succinctly,
and in a personable manner using markdown and even add some personal flair with appropriate emojis.

# Safety
- You **should always** reference factual statements to search results based on [relevant documents]
- Search results based on [relevant documents] may be incomplete or irrelevant. You do not make assumptions
# Customer
You are helping {{firstName}} {{lastName}} to find answers to their questions.
Use their name to address them in your responses.

user:
{{question}}

```


- dict as sample input
```
---
name: Basic Prompt
description: A basic prompt that uses the GPT-3 chat API to answer questions
model:
    api: chat
    configuration:
      type: azure_openai
      azure_deployment: gpt-35-turbo
      connection: azure_open_ai_connection
    parameters:
      max_tokens: 128
      temperature: 0.2
inputs:
  firstName:
    type: string
    default: John
  lastName:
    type: string
    default: Doh
  question:
    type: string
sample:
  question: what is the result of 1+1?
---
system:
You are an AI assistant who helps people find information.
As the assistant, you answer questions briefly, succinctly,
and in a personable manner using markdown and even add some personal flair with appropriate emojis.

# Safety
- You **should always** reference factual statements to search results based on [relevant documents]
- Search results based on [relevant documents] may be incomplete or irrelevant. You do not make assumptions
# Customer
You are helping {{firstName}} {{lastName}} to find answers to their questions.
Use their name to address them in your responses.

user:
{{question}}

```


Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-04-18 16:27:35 +08:00
Brynn Yin 245fa8b85f [Doc] Build changelog to docsite (#2860)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

![image](https://github.com/microsoft/promptflow/assets/24237253/3114d22d-9ffb-4c92-ba6b-1f702b48ead5)


# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
Co-authored-by: Philip Gao <yigao@microsoft.com>
2024-04-18 16:10:13 +08:00
chjinche 9b66af1d43 Introduce universal contract LLM tool and combine aoai/openai vision tools to "LLM-Vision" tool (#2223)
# Description

## Motivation
The contract of previous llm tool is not universal, making it hard to
support new features. Modification of previous contract is
cost-inefficient and unsustainable. It also introduces significant
coupling of different components, and additional release pipeline of
tool spec.

Also, we plan to support llm series tools by modality for better user
experience.

User are asking for "tools"/"tool_choice" support, for example #2741
#2087

## Solution
Shifting llm tool to universal contract, and adding llm-vision tool.
Add "tools"/"tool_choice" to llm tool.

# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [X] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Yao <46446115+16oeahr@users.noreply.github.com>
Co-authored-by: yalu4 <yalu4@microsoft.com>
Co-authored-by: cs_lucky <si.chen@microsoft.com>
Co-authored-by: chenslucky <75061414+chenslucky@users.noreply.github.com>
2024-04-18 11:47:21 +08:00
Ying Chen aec51a01a6 [Doc] Add reference doc for pf service cli. (#2774)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Ying Chen <2601502859@qq.com>
2024-04-12 17:18:05 +08:00
Brynn Yin a663abb01c Add some package and resource checks (#2751)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.
- Refine workspace connection provider error handling
- Fix run name get dir name empty error
- Limit workspace type to 'project' and 'default' if use workspace
connection

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
2024-04-11 19:19:00 +08:00
Alexander KIRILOV 8332f126c6 [SDK/CLI] added autocompletion for pf cli (#2534)
# Description

This pull request adds shell (bash / zsh) autocompletion for the "pf"
cli tool.
It is based on "argcomplete" library
https://kislyuk.github.io/argcomplete/ and inspired by "az" cli

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [x] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Ying Chen <2601502859@qq.com>
2024-04-10 16:11:55 +08:00
melionel 2be96ef280 [Feature][Tools] llm vision tool support detail parameter (#2547)
# Description

Add 'detail' parameter on 'Azure OpenAI GPT-4 Turbo with Vision" tool
and "OpenAI GPT-4V" tool.

Local test:

![image](https://github.com/microsoft/promptflow/assets/9986857/f1f12722-f917-4f07-b7ee-ab20fc353328)

![image](https://github.com/microsoft/promptflow/assets/9986857/a6dd9389-1c02-4264-95df-d2bac398b6d7)


![image](https://github.com/microsoft/promptflow/assets/9986857/e0c6fc80-f44e-4410-b6f3-cfa284e5e4d9)

![image](https://github.com/microsoft/promptflow/assets/9986857/dc38baf0-f79a-46d7-b092-6db202b35ae8)

Cloud test:
promptflow-tools==0.0.349


![image](https://github.com/microsoft/promptflow/assets/9986857/ffa60176-6aea-48a1-b18d-b090615995fd)


![image](https://github.com/microsoft/promptflow/assets/9986857/b54f6813-2647-4ec9-8dfc-1fdde8a72346)



# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Meng Lan <mengla@microsoft.com>
2024-04-02 17:16:36 +08:00
Brynn Yin d396124bc6 [Doc] Update doc reference pypi (#2542)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

Signed-off-by: Brynn Yin <biyi@microsoft.com>
2024-03-29 14:49:05 +08:00
Clement Wang ef877273f2 update imports in doc and examples (#2499)
# Description

Avoid imports from root namespace in docs & examples.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-03-29 09:55:49 +08:00
Brynn Yin dffa5f773c [Doc] Update doc for multiple api source (#2521)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
2024-03-28 16:06:26 +08:00
Xingzhi Zhang ffdc46acb8 fix: resume-from doesn't take effect (#2486)
# Description

Fix the bug that `resume-from` actually doesn't work and add
corresponding tests.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [x] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
Co-authored-by: Brynn Yin <biyi@microsoft.com>
2024-03-26 19:39:15 +08:00
chjinche 4d1a8a9f45 Add doc of how to write a chat prompt (#2442)
# Description

Issue: customer reported tsg link in error message is broken in #2308,
which was caused by deletion in azure_insider repo. Another issue is we
found previous tsg does not cover how to write a chat prompt,
specifically how to assign role, and role properties.

Solution: add doc, and update aka short link.

# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [X] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-03-26 16:26:02 +08:00
Honglin f613835b5a [Doc] Update pfazure run doc (#2271)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-03-08 15:32:18 +08:00
Han Wang 01e481f4dd [Doc] Add environment variable in flow.dag.yaml reference doc (#2263)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.
This pull request primarily includes changes to the
`flow-yaml-schema-reference.md` file, which is part of the documentation
for the YAML schema. The changes mainly involve modifications to the
formatting of the tables in the document. The most significant changes
include the adjustment of the column width in several tables and the
addition of a new field, `environment_variables`, in the `nodes`
section.

Formatting changes:

*
[`docs/reference/flow-yaml-schema-reference.md`](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39L12-R12):
Adjusted the column width in the tables under the `YAML syntax`, `Flow
input`, `Nodes`, and `Node variants` sections. These changes help to
improve the readability of the tables.
[[1]](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39L12-R12)
[[2]](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39R21-R28)
[[3]](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39L47-R48)
[[4]](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39L64-R65)

Addition of new field:

*
[`docs/reference/flow-yaml-schema-reference.md`](diffhunk://#diff-ee48baad7764b577cd9b539588af7e0d9856d7faedd0489dfcf0ec5e3e27bb39R21-R28):
Added a new field, `environment_variables`, to the `nodes` section. This
field allows users to set environment variables by specifying a property
path and value.
# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-03-08 14:51:37 +08:00
Brynn Yin cf25abba1c [Internal] Store column mapping in local run (#2202)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
2024-03-05 11:55:09 +08:00
Brynn Yin 90a0a9ee82 [SDK] Support local&cloud create run resume_from parameter (#2141)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.
This pull request introduces the feature to resume runs from existing
runs in the PromptFlow SDK and CLI. The changes primarily revolve around
the introduction of the `resume_from` parameter across various files and
functions. The `resume_from` parameter allows users to create a run that
resumes from an existing run. The new run reuses the succeeded line
result of the original run and only runs the remaining/failed lines.

Key changes include:

Addition of `resume_from` functionality:

*
[`src/promptflow/promptflow/_cli/_pf/_run.py`](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeR97-R100):
Added `resume_from` parameter to the `add_run_create_common` function
and the `create_run` function. The `create_run` function now checks for
the presence of `resume_from` and calls the appropriate function
accordingly.
[[1]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeR97-R100)
[[2]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeR113)
[[3]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeL131-R144)
[[4]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeL411-R423)
[[5]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeL560-R575)
[[6]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeR585)
[[7]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeL581-R595)
[[8]](diffhunk://#diff-0c9317bbb4cca7fd867af1f48509e5e17aa2a22fe09612467bd002ebfc6d1ebeL591-R640)

*
[`src/promptflow/promptflow/_sdk/_pf_client.py`](diffhunk://#diff-c100045cd304dbaa66dd61b7087f78b813ce01e8566d0b823b293bb35755eccfL56-R56):
Added `resume_from` parameter to the `run` function. The function now
checks for the presence of `resume_from` and calls the appropriate
function accordingly.
[[1]](diffhunk://#diff-c100045cd304dbaa66dd61b7087f78b813ce01e8566d0b823b293bb35755eccfL56-R56)
[[2]](diffhunk://#diff-c100045cd304dbaa66dd61b7087f78b813ce01e8566d0b823b293bb35755eccfR67)
[[3]](diffhunk://#diff-c100045cd304dbaa66dd61b7087f78b813ce01e8566d0b823b293bb35755eccfR116-R144)

*
[`src/promptflow/promptflow/_sdk/_run_functions.py`](diffhunk://#diff-3985b4097752d2257ce69e7105b3ece49a8a6238c22608a9e28a20218cd9a9bbR17-R22):
Added `_resume_run` function to handle the creation of runs that resume
from existing runs.

*
[`src/promptflow/promptflow/_sdk/_submitter/run_submitter.py`](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cR42-R63):
Added `resume` function to handle the resumption of runs. Modified
`_run_bulk` and `_submit_bulk_run` functions to handle runs that resume
from existing runs.
[[1]](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cR42-R63)
[[2]](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cL55-R80)
[[3]](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cL83-R98)
[[4]](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cR131-R134)
[[5]](diffhunk://#diff-e3499cf713c66612d91723759de1c5076c22689b2ce2c89678f82de624b57c2cR143-R144)

Updates to documentation:

*
[`docs/reference/pf-command-reference.md`](diffhunk://#diff-a7bd0e1379994523789706dd8bbbd61f2b4970ebda4e53a241a4c1ec0ef4a727R469):
Updated the documentation for the `pf run create` command to include the
`resume_from` parameter.
[[1]](diffhunk://#diff-a7bd0e1379994523789706dd8bbbd61f2b4970ebda4e53a241a4c1ec0ef4a727R469)
[[2]](diffhunk://#diff-a7bd0e1379994523789706dd8bbbd61f2b4970ebda4e53a241a4c1ec0ef4a727R498-R509)

*
[`docs/reference/pfazure-command-reference.md`](diffhunk://#diff-eaed2450485fcb6f3d3fbe556d2c87ddf8e13f02bf3727df69dc146745075607R195):
Updated the documentation for the `pfazure run create` command to
include the `resume_from` parameter.
[[1]](diffhunk://#diff-eaed2450485fcb6f3d3fbe556d2c87ddf8e13f02bf3727df69dc146745075607R195)
[[2]](diffhunk://#diff-eaed2450485fcb6f3d3fbe556d2c87ddf8e13f02bf3727df69dc146745075607R245-R249)

*
[`src/promptflow/CHANGELOG.md`](diffhunk://#diff-41ec3f7c4b5d4c0e670407d3c00a03a6966d7ebf617b1536473e33a12e2bc765R3-R13):
Updated the changelog to include the new `resume_from` feature.

Other changes:

*
[`src/promptflow/promptflow/_cli/_pf_azure/_run.py`](diffhunk://#diff-d1106ac9efec0530a00183e566fba9267ce3921980b402013fd4c84472a612fcR414):
Updated the `dispatch_run_commands` function to handle runs that resume
from existing runs.

*
[`src/promptflow/promptflow/_sdk/_constants.py`](diffhunk://#diff-9ffef684cefef289f51e58b0aff1cd6cfa42363ace309d07f36dfe6559c5b84dR258):
Added `RESUME_FROM` to the `FlowRunProperties` class.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
Co-authored-by: Philip Gao <yigao@microsoft.com>
2024-03-01 18:50:39 +08:00
Han Wang 251e8ea9ae [SDK][azure]Add identity support for run for automatic runtime (#2157)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.
This pull request introduces identity support for automatic runtime in
the PromptFlow SDK and CLI. The changes include the addition of identity
configuration in the YAML schema, the introduction of new Enums for
identity configuration, and the addition of identity resolution in the
run operations.

Changes to YAML schema and documentation:

*
[`docs/reference/run-yaml-schema-reference.md`](diffhunk://#diff-f57019f0c08dc1936b08a86c6e3cd020676f614069559309a6b2216b7b9c89b3R29-R30):
Added a new `identity` field in the schema and updated the documentation
accordingly. The `identity` field is an object that supports two types
of identities: `managed` and `user_identity`.
[[1]](diffhunk://#diff-f57019f0c08dc1936b08a86c6e3cd020676f614069559309a6b2216b7b9c89b3R29-R30)
[[2]](diffhunk://#diff-f57019f0c08dc1936b08a86c6e3cd020676f614069559309a6b2216b7b9c89b3R39-R46)

*
[`src/promptflow/promptflow/_sdk/schemas/_run.py`](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fR9-R14):
Introduced `ManagedIdentitySchema` and `UserIdentitySchema` for identity
configuration in the YAML schema. The `RunSchema` now includes an
`identity` field that can be either of the two new schema types.
[[1]](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fR9-R14)
[[2]](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fR39-R55)
[[3]](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fR112-R118)

Changes to the SDK:

*
[`src/promptflow/promptflow/_sdk/_constants.py`](diffhunk://#diff-9ffef684cefef289f51e58b0aff1cd6cfa42363ace309d07f36dfe6559c5b84dR468-R485):
Added two new Enums `IdentityConfigurationType` and `IdentityKeys` for
identity configuration.

*
[`src/promptflow/promptflow/_sdk/entities/_run.py`](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020R32):
The `Run` class now includes an `_identity` field. The `Run` class's
`__init__` and `_to_rest_object` methods have been updated to handle the
new identity configuration.
[[1]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020R32)
[[2]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020R185)
[[3]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020R557-R559)
[[4]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020R582)

*
[`src/promptflow/promptflow/azure/operations/_run_operations.py`](diffhunk://#diff-8edc3f1b002af9c7a0059d7d6ae7a25d1983836b6736d0d7e8c8537c6c3781c2R41):
The `RunOperations` class now includes a `_resolve_identity` method to
resolve the identity configuration for a run. The `__init__` method and
`_resolve_dependencies_in_parallel` method have been updated to handle
the new identity configuration.
[[1]](diffhunk://#diff-8edc3f1b002af9c7a0059d7d6ae7a25d1983836b6736d0d7e8c8537c6c3781c2R41)
[[2]](diffhunk://#diff-8edc3f1b002af9c7a0059d7d6ae7a25d1983836b6736d0d7e8c8537c6c3781c2R101)
[[3]](diffhunk://#diff-8edc3f1b002af9c7a0059d7d6ae7a25d1983836b6736d0d7e8c8537c6c3781c2R842)
[[4]](diffhunk://#diff-8edc3f1b002af9c7a0059d7d6ae7a25d1983836b6736d0d7e8c8537c6c3781c2R975-R1013)

Changes to the CLI:

*
[`src/promptflow/CHANGELOG.md`](diffhunk://#diff-41ec3f7c4b5d4c0e670407d3c00a03a6966d7ebf617b1536473e33a12e2bc765R13):
Updated the changelog to include the new identity support for automatic
runtime.

Changes to tests:

*
[`src/promptflow/tests/sdk_cli_azure_test/e2etests/test_run_operations.py`](diffhunk://#diff-b63fdccdd1a3a293abe7799c0a231a7226614f726b6de1298f7e0233af26f128R19-R20):
Added new tests to validate the identity configuration for automatic
runtime.
[[1]](diffhunk://#diff-b63fdccdd1a3a293abe7799c0a231a7226614f726b6de1298f7e0233af26f128R19-R20)
[[2]](diffhunk://#diff-b63fdccdd1a3a293abe7799c0a231a7226614f726b6de1298f7e0233af26f128R1144-R1193)

*
[`src/promptflow/tests/sdk_cli_azure_test/unittests/test_run_operations.py`](diffhunk://#diff-e61f9744c35acda81ccf7220c70aad98d0a258eec5be24997c151732a6d1ac0eR2-R15):
Added new unit tests to validate the identity resolution in
`RunOperations`.
[[1]](diffhunk://#diff-e61f9744c35acda81ccf7220c70aad98d0a258eec5be24997c151732a6d1ac0eR2-R15)
[[2]](diffhunk://#diff-e61f9744c35acda81ccf7220c70aad98d0a258eec5be24997c151732a6d1ac0eR26-R81)

Changes to test configurations:

*
[`src/promptflow/tests/test_configs/runs/sample_bulk_run_with_managed_identity.yaml`](diffhunk://#diff-62088854bccb57b83136d73c7396e8d65b23856d49886d992690669f5acb19e4R1-R10):
Added a new test configuration for a run with a managed identity.

*
[`src/promptflow/tests/test_configs/runs/sample_bulk_run_with_user_identity.yaml`](diffhunk://#diff-1d8af90c7da2c611161942ac3ed0d3acdda2b567ec76817ad1359251dabed0d2R1-R9):
Added a new test configuration for a run with a user identity.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-02-29 12:00:48 +08:00
Honglin e2238c6bab [SDK/CLI] Add pfazure flow update (#2082)
# Description

[SDK/CLI] Support `pfazure flow update` to update flow's metadata like
`display_name`, `description` or `tags`.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-02-23 18:40:19 +08:00
Honglin 551886302c [SDK/CLI] Support setting timeout for pfazure run stream (#2002)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-02-21 17:26:48 +08:00
Honglin c7a58311c5 [Doc] Fix 404 doc link (#2063)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-02-21 15:06:25 +08:00
Clement Wang d4942cd68b [Sample] rename chat-basic (#2028)
# Description

Rename sample name to 'chat-basic' following naming pattern chat-xxx

![image](https://github.com/microsoft/promptflow/assets/47586720/f71f13dc-d492-4e29-a607-16b40f4aec3e)


# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Philip Gao <yigao@microsoft.com>
2024-02-18 14:18:30 +08:00
Han Wang cb81d868d4 [SDK][azure] Stop support specifying idle_time_before_shutdown_minutes for automatic runtime (#1947)
# Description
This pull request includes changes across multiple files to modify the
handling of resource allocation for runtime sessions. The key changes
include replacing the `idle_time_before_shutdown_minutes` attribute with
a `compute` attribute, which specifies the compute instance for
automatic runtime sessions. The changes also include updates to handle
unsupported fields in the resources schema and tests to validate these
changes.

Documentation updates:

*
[`docs/reference/run-yaml-schema-reference.md`](diffhunk://#diff-f57019f0c08dc1936b08a86c6e3cd020676f614069559309a6b2216b7b9c89b3L33-R35):
Updated the Resources Schema to replace
`idle_time_before_shutdown_minutes` with `compute` in the table of keys,
types, and descriptions.

Codebase updates:

*
[`examples/tutorials/run-management/cloud-run-management.ipynb`](diffhunk://#diff-468c9ad6f92dc022ca6dcd03adcca1f816c9e2eb49f5a3cffa3e924531fa1917L199-R202):
Updated the tutorial to reflect the replacement of
`idle_time_before_shutdown_minutes` with `compute` in the resources
customization section.
*
[`src/promptflow/promptflow/_sdk/entities/_run.py`](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020L548-L554):
Removed references to `idle_time_before_shutdown_minutes` and its
conversion to seconds in the `_to_rest_object` method.
[[1]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020L548-L554)
[[2]](diffhunk://#diff-14f4d7a1d9b077c7b749230a92628782f990e1fc7cb741b20ff894f868327020L577)
*
[`src/promptflow/promptflow/_sdk/schemas/_run.py`](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fL33):
Removed `idle_time_before_shutdown_minutes` from `ResourcesSchema` and
added an exception for unknown fields in resources in `RunSchema`.
[[1]](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fL33)
[[2]](diffhunk://#diff-db38cc07d25efdbc0622e8e9352e07e34c502d36bdad1954bcd52db156192c9fL92-R92)

Testing updates:

*
[`src/promptflow/tests/sdk_cli_azure_test/unittests/test_flow_entity.py`](diffhunk://#diff-44e987aed05f781a28e90e24fda551a5391751a1d4f59af03a8c1c05cb058720L122-R129):
Updated tests to check for the `compute` attribute instead of
`idle_time_before_shutdown_minutes` and added a test to check for
unsupported fields in resources.

Configuration updates:

*
[`src/promptflow/tests/test_configs/runs/sample_bulk_run_with_idle_time.yaml`](diffhunk://#diff-07248425124e04633a69ce77f442a5e2f1483afa2a9455d35a13d632dc8c03fbR1-R10):
Added a new test configuration file with an unsupported
`idle_time_before_shutdown_minutes` field in resources.
*
[`src/promptflow/tests/test_configs/runs/sample_bulk_run_with_resources.yaml`](diffhunk://#diff-011e4c072e09f76ed8eb59f17d81238abd9c172bcc660966df8654678580d106L10):
Removed `idle_time_before_shutdown_minutes` from the resources
configuration.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-02-04 16:05:04 +08:00
Ying Chen 0f55ffd98c Add pf upgrade doc. (#1740)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

Co-authored-by: Ying Chen <2601502859@qq.com>
2024-01-16 13:46:13 +08:00
Brynn Yin 9c6991c080 [CLI] Add --skip-open-browser for flow serve (#1743)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Signed-off-by: Brynn Yin <biyi@microsoft.com>
Co-authored-by: Zhengfei Wang <38847871+zhengfeiwang@users.noreply.github.com>
2024-01-15 14:54:58 +08:00
Philip Gao 3ea6c6d8cd Update pf-command-reference.md (#1715)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-01-11 15:09:46 +08:00
chenslucky 8038365024 Update tools documents about openai parameters (#1414)
# Description

Update tools documents about openai parameters.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: cs_lucky <si.chen@microsoft.com>
2024-01-09 10:05:50 +08:00
Robben Wang e6dbc4ba4c Add doc about python tools' Keyword Arguments Support (#1642)
# Description
Add doc about python tools' Keyword Arguments Support. The change
includes a code snippet and a screenshot showcasing for the feature.



# All Promptflow Contribution checklist:
- [X] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [X] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.

Co-authored-by: robbenwang <robbenwang@microsoft.com>
2024-01-03 17:37:46 +08:00
Honglin b504bef000 [Doc] Add doc for pfazure run download (#1632)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2024-01-02 15:15:53 +08:00
zhen 789034e912 [Tool] Support validate tools (#1527)
# Description
- Tool validate CLI:
Help:

![image](https://github.com/microsoft/promptflow/assets/17938940/1754c65b-4a7a-4914-95a5-41082cc5e8a6)

Validate succeed:

![image](https://github.com/microsoft/promptflow/assets/17938940/03b9f541-dd73-48a6-9eeb-76d9ff485f33)

Validate failed:

![image](https://github.com/microsoft/promptflow/assets/17938940/0beddc74-26c8-4240-9f9e-bda8f8fcffa8)

- SDK experience:
```
from package_name import tool_func 

client = PFClient()
validation_result = client.tools.validate(source=tool_func, raise_error=False) 

if not validation_result.passed: 
    for name, error_message in validation_result.error_messages.items(): 
        print(error_message) 
```
validate result:

![image](https://github.com/microsoft/promptflow/assets/17938940/2f8894a7-8cb8-4e9e-a48e-4e85b255d5dc)

raise exception:

![image](https://github.com/microsoft/promptflow/assets/17938940/cedc6fd4-51f7-4ef7-9a79-2332f654460c)

- List package tool
It will print warning log if there are invalid tools in package.

![image](https://github.com/microsoft/promptflow/assets/17938940/e073d66a-f565-44dd-9687-092fa37dc01d)

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.
2023-12-21 19:20:22 +08:00
Ming Gu 00494dd439 Add bug bash sample flows (#1148)
# Description

Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [X] Title of the pull request is clear and informative.
- [X] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [X] Pull request includes test coverage for the included changes.

---------

Co-authored-by: minggu <migu@microsoft.com>
Co-authored-by: Philip Gao <yigao@microsoft.com>
Co-authored-by: Zhengfei Wang <zhengfei.wang@microsoft.com>
2023-12-20 17:31:01 +08:00
melionel 79ae944a7c [Tools] add new tool to support Azure OpenAI GPT-4 Turbo with Vision (#1486)
- Description

This pull request introduces a new tool called "Azure OpenAI GPT-4 Turbo
with Vision" to the codebase. It includes changes to multiple files to
add support for analyzing images and answering questions about them
using Azure OpenAI GPT-4 Turbo with Vision. The most important changes
include adding the new tool to the `aoai_gpt4v.yaml` file, adding a test
case to check image input support, and adding documentation for the new
tool.

- Validation result:

*local*:

![image](https://github.com/microsoft/promptflow/assets/9986857/6bfcbef5-21e9-49b4-aa73-342073ede34e)

![image](https://github.com/microsoft/promptflow/assets/9986857/9656fdb7-43e2-46f0-ae67-c6ec6e0b9ef7)

*cloud*

![image](https://github.com/microsoft/promptflow/assets/9986857/e9816d95-8fbf-48b6-8a6f-b13ee9e03534)

![image](https://github.com/microsoft/promptflow/assets/9986857/04e436b1-8371-4441-8786-f193d6b545df)

![image](https://github.com/microsoft/promptflow/assets/9986857/ba2c7150-5376-46c8-9f24-c6b99659d80c)


Please add an informative description that covers that changes made by
the pull request and link all relevant issues.

# All Promptflow Contribution checklist:
- [ ] **The pull request does not introduce [breaking changes].**
- [ ] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [ ] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [ ] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [ ] Title of the pull request is clear and informative.
- [ ] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [ ] Pull request includes test coverage for the included changes.

---------

Co-authored-by: Meng Lan <mengla@microsoft.com>
2023-12-15 16:46:17 +08:00
Gerard@msft 910536bb1c Rename Open Source to Open Model LLM Tool (#1437)
# Description

As title: Rename Open Source to Open Model LLM Tool to meet CELA
requirements.

# All Promptflow Contribution checklist:
- [x] **The pull request does not introduce [breaking changes].**
- [x] **CHANGELOG is updated for new features, bug fixes or other
significant changes.**
- [x] **I have read the [contribution guidelines](../CONTRIBUTING.md).**
- [x] **Create an issue and link to the pull request to get dedicated
review from promptflow team. Learn more: [suggested
workflow](../CONTRIBUTING.md#suggested-workflow).**

## General Guidelines and Best Practices
- [x] Title of the pull request is clear and informative.
- [x] There are a small number of commits, each of which have an
informative message. This means that previously merged commits do not
appear in the history of the PR. For more information on cleaning up the
commits in your PR, [see this
page](https://github.com/Azure/azure-powershell/blob/master/documentation/development-docs/cleaning-up-commits.md).

### Testing Guidelines
- [x] Pull request includes test coverage for the included changes.
2023-12-11 21:05:29 +08:00