Comments (11)
@prithvi2226 that would be awesome!
from autogen.
@LittleLittleCloud If possible, could you please assign this task to me? However, if this action doesn't make a significant difference, I am fine with it. The main priority is to ensure the issue is resolved and the repository progresses smoothly.
from autogen.
@prithvi2226 Do you need more time on this one? Also please let me know if you need help!
from autogen.
You nailed it!
from autogen.
Hi @LittleLittleCloud! This task seems to be interesting! Can I work on this task?
from autogen.
@prithvi2226 Any update on this issue
from autogen.
@prithvi2226 Any update on this issue
Hey @LittleLittleCloud , I am still working on it, been remote for a while, I can give you an update by Tuesday!? If that's okay?
from autogen.
Hi @LittleLittleCloud! Thank you very much for checking up on me, and thank you very much for taking the time to help me out with this. I am very sorry from my side, for not giving an update, to solve this bug.
Please Correct me if I am wrong, I have decided to work on the file dotnet/src/AutoGen.SourceGenerator/DocumentCommentExtension.cs
, and DocumentCommentExtension
class contains methods for handling documentation comments, and it's where I am going to add the logic to escape double quotes in the comments. And, in the method 'GetParameterDescriptionFromDocumentationCommentTriviaSyntax' looks like it processes descriptions for parameters from documentation comments. I hope I am on the right track! Thank you very much!
from autogen.
@prithvi2226 Thanks for your response.
IMO you don't need to go that further into DocumentCommentExtension.cs, the quickest solution is to encode "
properly in
"
-> ""
)
For example, when the comment contains "
/// <summary>
/// I have " in the summary and the generated code is breaking!
/// </summary>
/// <param name="city"></param>
/// <returns></returns>
[Function]
public async Task<string> GetWeatherAsync(string city)
{
return await Task.FromResult($"The weather in {city} is sunny.");
}
As you can see, "
breaks the generated code because FunctionTemplate.tt
encodes description using @"...."
and didn't process the "
in the comment description.
The quickest fix is to encode "
in description by doubling it (""
). This is how "
is encoded as well in verbatim string.
from autogen.
Hi @LittleLittleCloud ,
Thank you very much for your guidance. Based on your suggestion, I will implement the fix directly in the FunctionCallTemplate.tt file. Here are the steps I plan to take:
Planned Changes:
- Modify the FunctionCallTemplate.tt File:
Locating the line that assigns the description (around line 84):
Description = @"<#=parameter.Description#>",
- I will modify this line to properly encode double quotes by doubling them (""), like so:
Description = @"<#= parameter.Description.Replace("\"", "\"\"") #>",
This approach should correctly handle double quotes in comments and prevent the generated code from breaking.
Please let me know if this solution looks good to you, and I will proceed with making these changes.
Thank you once again for your assistance!
Best regards,
Prithvi
from autogen.
Hi @LittleLittleCloud ! I have created a pull request, let me know what you think about it. Thank you very much for your guidance and support. I would love to connect with you on Github or Slack to continue supporting this project.
from autogen.
Related Issues (20)
- [Roadmap]: Enhanced RAG Support HOT 2
- [Bug]: autogen can't work with vllm v0.5.1 HOT 5
- [Feature Request]: Support for function calling and images in MessageHistoryLimiter
- [Bug]: AutogenStudio 0.1.3 GroupChat Skills being overwritten. HOT 1
- [.Net][API Break Change]: Deprecate `TextMessageUpdate`
- [.Net][API Break Change]: Deprecate `ToolCallUpdate`
- [.Net][Feature Request]: Allow more options to be passed into `OpenAIChatAgent` constructor
- [Bug]: AutoGen.NET middelware overview documentation contains errors in the example code.
- [.Net][API Break Change] In `AutoGen.SourceGenerator`, stop generating `FunctionDefinition`
- [.Net][Feature Request]: Enable dotnet format check in ci
- [Issue][.Net] Why does the all-in-one Autogen package depend on all clients? HOT 2
- [.Net][Document]: Use AutoGen.Net agent as model in AG Studio HOT 1
- [.Net][Bug]: AutoGen.WebAPI not released
- [Bug]: Websocket demo not working
- [Roadmap]: Google Integrations
- [Issue]: Gemini models do not execute code in Autogen Studio
- [.Net][Feature Request]: Rename the namespace of AutoGen.WebAPI from AutoGen.Service to AutoGen.WebAPI
- [Issue]: How can I disable caching? HOT 3
- [Bug]: Handle CTRL+C gracefully
- [Bug]: Not understanding warning message from autogen during ConverseableAgent creation.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from autogen.