12 references to TypePropertyName
Microsoft.Extensions.AI.Abstractions (12)
Utilities\AIJsonUtilities.Schema.Create.cs (11)
150
schema[
TypePropertyName
] = "object"; // Method schemas always hardcode the type as "object".
250
return new JsonObject { [
TypePropertyName
] = null };
287
if (ctx.TypeInfo.Type.IsEnum && objSchema.ContainsKey(EnumPropertyName) && !objSchema.ContainsKey(
TypePropertyName
))
289
objSchema.InsertAtStart(
TypePropertyName
, "string");
310
obj[
TypePropertyName
] = new JsonArray { (JsonNode)numericType, (JsonNode)"null" };
314
obj[
TypePropertyName
] = (JsonNode)numericType;
325
if (objSchema.TryGetPropertyValue(
TypePropertyName
, out JsonNode? typeKeyWord) &&
331
objSchema[
TypePropertyName
] = new JsonArray { (JsonNode)typeValue, (JsonNode)"null" };
336
if (nullableElement.IsEnum && objSchema.ContainsKey(EnumPropertyName) && !objSchema.ContainsKey(
TypePropertyName
))
338
objSchema.InsertAtStart(
TypePropertyName
, new JsonArray { (JsonNode)"string", (JsonNode)"null" });
637
if (!schema.TryGetPropertyValue(
TypePropertyName
, out JsonNode? typeNode))
Utilities\AIJsonUtilities.Schema.Transform.cs (1)
145
schemaObj.TryGetPropertyValue(
TypePropertyName
, out JsonNode? typeSchema) &&