Skip to content

Commit

Permalink
Merge pull request #9 from Uralstech/unstable
Browse files Browse the repository at this point in the history
UGemini v1.2.3
  • Loading branch information
Uralstech authored Jul 10, 2024
2 parents 52e823e + 3a84436 commit 3b7a9f8
Show file tree
Hide file tree
Showing 176 changed files with 300 additions and 248 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/latexdocs
10 changes: 5 additions & 5 deletions Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ PROJECT_NAME = UGemini
# could be handy for archiving the generated documentation or if some version
# control system is used.

PROJECT_NUMBER = 1.2.2
PROJECT_NUMBER = 1.2.3

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a
Expand All @@ -74,7 +74,7 @@ PROJECT_ICON =
# entered, it will be relative to the location where doxygen was started. If
# left blank the current directory will be used.

OUTPUT_DIRECTORY = C:/Users/asus/UGemini/docs
OUTPUT_DIRECTORY =

# If the CREATE_SUBDIRS tag is set to YES then doxygen will create up to 4096
# sub-directories (in 2 levels) under the output directory of each output format
Expand Down Expand Up @@ -1338,7 +1338,7 @@ GENERATE_HTML = YES
# The default directory is: html.
# This tag requires that the tag GENERATE_HTML is set to YES.

HTML_OUTPUT = ./
HTML_OUTPUT = docs

# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each
# generated HTML page (for example: .htm, .php, .asp).
Expand Down Expand Up @@ -1996,15 +1996,15 @@ EXTRA_SEARCH_MAPPINGS =
# If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output.
# The default value is: YES.

GENERATE_LATEX = NO
GENERATE_LATEX = YES

# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
# it.
# The default directory is: latex.
# This tag requires that the tag GENERATE_LATEX is set to YES.

LATEX_OUTPUT = latex
LATEX_OUTPUT = latexdocs

# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be
# invoked.
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,3 +84,5 @@ Follow the steps detailed in the OpenUPM installation method and only install th
### Documentation

See <https://github.com/Uralstech/UGemini/blob/master/UGemini/Packages/com.uralstech.ugemini/Documentation~/README.md>.

See <https://uralstech.github.io/UGemini/> for reference manual.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@

`GeminiManager.Compute` and parts of related types have been deprecated. Please check `README_OLD.md` for documentation regarding the deprecated code.

### Reference Manual

See `refman.pdf` for the offline reference manual or go to <https://uralstech.github.io/UGemini/>.

### Table of Contents

- [**Setup**](#setup)
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace Uralstech.UGemini
public static class EnumExtensions
{
/// <summary>
/// Converts a <see cref="GeminiContentType"/> to its <see href="https://www.iana.org/assignments/media-types/media-types.xhtml">MIME type</see>.
/// Converts a <see cref="GeminiContentType"/> to its <a href="https://www.iana.org/assignments/media-types/media-types.xhtml">MIME type</a>.
/// </summary>
/// <param name="enumValue">The <see cref="GeminiContentType"/> value.</param>
/// <returns>The MIME type as a string.</returns>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public static GeminiContent GetContent(string message, Texture2D image, GeminiRo
/// Creates a new <see cref="GeminiContent"/> from a role, message and <see cref="AudioClip"/>.
/// </summary>
/// <remarks>
/// Requires <see href="https://openupm.com/packages/com.utilities.encoder.wav/">Utilities.Encoding.Wav</see>.
/// Requires <a href="https://openupm.com/packages/com.utilities.encoder.wav/">Utilities.Encoding.Wav</a>.
/// </remarks>
/// <param name="role">The role of the content creator.</param>
/// <param name="message">The message.</param>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public class GeminiContentBlob
/// Converts the given <see cref="AudioClip"/> to a <see cref="GeminiContentBlob"/>.
/// </summary>
/// <remarks>
/// Requires <see href="https://openupm.com/packages/com.utilities.encoder.wav/">Utilities.Encoding.Wav</see>.
/// Requires <a href="https://openupm.com/packages/com.utilities.encoder.wav/">Utilities.Encoding.Wav</a>.
/// </remarks>
/// <param name="audio">The <see cref="AudioClip"/> to use.</param>
/// <returns>A new <see cref="GeminiContentBlob"/> object.</returns>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@

namespace Uralstech.UGemini
{
/// <summary>
/// Extensions for Unity types.
/// </summary>
public static class UnityExtensions
{
#if UTILITIES_ENCODING_WAV_1_0_0_OR_GREATER && UTILITIES_AUDIO_1_0_0_OR_GREATER
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ public string GetEndpointUri(GeminiRequestMetadata metadata)
/// <summary>
/// Creates a new <see cref="GeminiFileGetRequest"/>.
/// </summary>
/// <param name="fileId">The ID of the file to get.</param>
/// <param name="useBetaApi">Should the request use the Beta API?</param>
public GeminiFileListRequest(bool useBetaApi = true)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

namespace Uralstech.UGemini.FileAPI
{
/// <summary>
/// Metadata for a file uploaded to the File API.
/// </summary>
[JsonObject(NamingStrategyType = typeof(CamelCaseNamingStrategy))]
public class GeminiFile
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@ public enum GeminiSchemaDataFormat
Binary,

/// <summary>
/// Date string as defined by "full-date - <see href="https://datatracker.ietf.org/doc/html/rfc3339#section-5.6">[!RFC3339]</see>"
/// Date string as defined by <a href="https://datatracker.ietf.org/doc/html/rfc3339#section-5.6">full-date - RFC 3339</a>.
/// </summary>
Date,

/// <summary>
/// Date and time string as defined by "date-time - <see href="https://datatracker.ietf.org/doc/html/rfc3339#section-5.6">[!RFC3339]</see>"
/// Date and time string as defined by <a href="https://datatracker.ietf.org/doc/html/rfc3339#section-5.6">date-time - RFC 3339</a>.
/// </summary>
DateTime,
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
namespace Uralstech.UGemini.Schema
{
/// <summary>
/// Contains the list of OpenAPI data types as defined by <see href="https://spec.openapis.org/oas/v3.0.3#data-types"/>.
/// Contains the list of OpenAPI data types as defined by the <a href="https://spec.openapis.org/oas/v3.0.3#data-types">OpenAPI Specification</a>.
/// </summary>
[JsonConverter(typeof(StringEnumConverter))]
public enum GeminiSchemaDataType
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class GeminiFunctionCall
/// Optional. The function parameters and values in JSON object format.
/// </summary>
/// <remarks>
/// See Protocol Buffer format here: <see href="https://protobuf.dev/reference/protobuf/google.protobuf/#google.protobuf.Struct"/>.
/// See Protocol Buffer <a href="https://protobuf.dev/reference/protobuf/google.protobuf/#google.protobuf.Struct">Struct</a>.
/// </remarks>
[JsonProperty("args", DefaultValueHandling = DefaultValueHandling.Ignore), DefaultValue(null)]
public JObject Arguments = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
namespace Uralstech.UGemini.Tools
{
/// <summary>
/// The response of a Gemini function call. Based on <see href="https://protobuf.dev/reference/protobuf/google.protobuf/#struct">Struct</see> format
/// The response of a Gemini function call. Based on the Protocol Buffer <a href="https://protobuf.dev/reference/protobuf/google.protobuf/#struct">Struct</a> type.
/// </summary>
[JsonObject(NamingStrategyType = typeof(CamelCaseNamingStrategy))]
public class GeminiFunctionResponseContent
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,43 +18,43 @@ public class GeminiManager : Singleton<GeminiManager>
private const string MultiPartFormDataSeperator = "xxxxxxxxxx";

/// <summary>
/// <see href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.0-pro-vision">
/// <a href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.0-pro-vision">
/// Note: Gemini 1.0 Pro Vision is deprecated. Use 1.5 Flash or 1.5 Pro instead.
/// <br/><br/>
/// Gemini 1.0 Pro Vision is a performance-optimized multimodal model that can perform visual-related tasks.<br/>
/// For example, 1.0 Pro Vision can generate image descriptions, identify objects present in images, provide<br/>
/// information about places or objects present in images, and more.
/// </see>
/// </a>
/// <br/><br/>
/// Supports image, video and text input.
/// </summary>
[Obsolete("Gemini 1.0 Pro Vision is deprecated. Use Use 1.5 Flash (Gemini1_5Flash) or 1.5 Pro (Gemini1_5Pro) instead.")]
public const string Gemini1_0ProVision = "gemini-pro-vision";

/// <summary>
/// <see href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.0-pro">
/// <a href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.0-pro">
/// Gemini 1.0 Pro is an NLP model that handles tasks like multi-turn text and code chat, and code generation.
/// </see>
/// </a>
/// <br/><br/>
/// Supports text input.
/// </summary>
public const string Gemini1_0Pro = "gemini-1.0-pro";

/// <summary>
/// <see href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.5-pro">
/// <a href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.5-pro">
/// Gemini 1.5 Pro is a mid-size multimodal model that is optimized for a wide-range of reasoning tasks.<br/>
/// 1.5 Pro can process large amounts of data at once, including 2 hours of video, 19 hours of audio,<br/>
/// codebases with 60,000 lines of code, or 2,000 pages of text.
/// </see>
/// </a>
/// <br/><br/>
/// Supports audio, image, video and text input.
/// </summary>
public const string Gemini1_5Pro = "gemini-1.5-pro";

/// <summary>
/// <see href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.5-flash">
/// <a href="https://ai.google.dev/gemini-api/docs/models/gemini#gemini-1.5-flash">
/// Gemini 1.5 Flash is a fast and versatile multimodal model for scaling across diverse tasks.
/// </see>
/// </a>
/// <br/><br/>
/// Supports audio, image, video and text input.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,18 @@

namespace Uralstech.UGemini.Utils.Singleton
{
/// <summary>
/// Utility class to make inheriting types singletons.
/// </summary>
/// <typeparam name="T">The type to be made a singleton.</typeparam>
public class Singleton<T> : MonoBehaviour
where T : Component
{
private static T s_instance;

/// <summary>
/// The active instance of type <typeparamref name="T"/>.
/// </summary>
public static T Instance
{
get
Expand Down
2 changes: 1 addition & 1 deletion UGemini/Packages/com.uralstech.ugemini/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"AI",
"Integration"
],
"version": "1.2.2",
"version": "1.2.3",
"unity": "2022.3",
"hideInEditor": false,
"documentationUrl": "https://github.com/Uralstech/UGemini/blob/master/UGemini/Packages/com.uralstech.ugemini/Documentation~/README.md",
Expand Down
Loading

0 comments on commit 3b7a9f8

Please sign in to comment.