You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: app-dev/devops-and-containers/functions/java-helloworld-AI-with-local-dev-and-oci-functions/README.md
+46-9Lines changed: 46 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -64,7 +64,7 @@ IAM user option will work on both cases above, as local and as OCI Function.
64
64
65
65
## Build and test
66
66
67
-
During following the steps of the <ahref="../java-helloworld-with-local-dev-and-oci-functions">Hello function example </a> adjust the <ahref="https://github.com/oracle-devrel/technology-engineering/blob/main/app-dev/devops-and-containers/functions/java-helloworld-AI-with-local-dev-and-oci-functions/files/src/main/java/com/example/HelloAIFunction.java#L93">line 93</a> to match your <code>GenAI service OCID</code>.
67
+
During following the steps of the <ahref="../java-helloworld-with-local-dev-and-oci-functions">Hello function example </a> adjust the <ahref="https://github.com/oracle-devrel/technology-engineering/blob/main/app-dev/devops-and-containers/functions/java-helloworld-AI-with-local-dev-and-oci-functions/files/src/main/java/com/example/HelloAIFunction.java#L131">line 131</a> to match your <code>GenAI service model OCID</code>.
68
68
69
69
<p>
70
70
@@ -74,21 +74,56 @@ Testing with curl (or copy-pasting the API Gateway deployment url to a browser):
June 13, 2024 is June 13, 1924. Here are some events that occurred on this date:
78
+
What happened today 01/17/2025 100 years ago ?
79
+
On January 17th, 1925, 100 years ago, the following events took place:
80
+
- In the US, President Calvin Coolidge delivered his annual State of the Union address to Congress. He discussed the thriving state of the national economy, emphasizing the record-high production of American industries and the growth of the country's merchant marine fleet. Coolidge also urged Congress to pass legislation facilitating world trade and improving diplomatic relations.
81
+
- The first Winter Sports Week was held in Chamonix, France. This event eventually evolved into the prestigious Chamonix International Festival of Sports and Cinema.
82
+
- The play "The New York Idea" by Langdon Mitchell premiered at the Ambassador Theatre on Broadway. It ran for 144 performances and received critical acclaim.
83
+
- The silent film "The Gold Rush" directed by Charlie Chaplin was released in the United States. It's a classic comedy that tells the story of a prospector during the Klondike Gold Rush. Chaplin's unique brand of physical comedy and the film's innovative effects delighted audiences.
84
+
- In Germany, the Weimar Republic experienced a political scandal known as the "German-Russian Trade and Credit Agreement." The agreement, which granted Germany a loan of 300 million marks from Russia, was signed secretly, leading to accusations of mismanagement and lack of transparency in the government. This incident further destabilized the already fragile Weimar Republic.
85
+
</pre>
80
86
81
-
1. The German airline Deutsche Lufthansa (DL) was officially founded on June 13, 1924. It is Germany's largest airline and is one of the world's largest airlines in terms of overall passengers carried.
82
-
83
-
2. The British Broadcasting Corporation (BBC) aired its first radio broadcast.
87
+
# Native image using GraalVM
88
+
89
+
GraalVM compiles your Java functions ahead of time into standalone binaries that start instantly, provide peak performance with no warmup, and use fewer resources. The key GraalVM benefits are: Low Resource Usage: Java applications compiled ahead-of-time by GraalVM require less memory and CPU to run.
90
+
91
+
<p>
92
+
93
+
To do this a Docker multi-stage build is used.
94
+
95
+
<p>
96
+
97
+
Before building the native image let's do a full maven build for the project to create the necessary libraries under <code>target/lib</code>:
98
+
99
+
<pre>
100
+
mvn clean install
101
+
</pre>
84
102
85
-
3. The Hollywood Sign was officially dedicated in California, marking the beginning of Hollywood's rise to prominence in the American film industry.
103
+
Then build the Docker container using <ahref="./files/Dockerfile.native">multi-stage Docker file</a> including the GraalVM native image compilation:
86
104
87
-
4. The Ford Motor Company introduced the firstassembly line to mass produce cars, making cars more accessible to the general public.
The GraalVM compilation stage requires quite a bit resources from your localhost so in case for example using Rancher desktop
110
+
think of increasing the CPU and memory for it to make the build faster.
111
+
112
+
<p>
113
+
114
+
In the <ahref="./files/Dockerfile.native">Dockerfile.native</a> two things are important: Including the <ahref="./files/reflection.json">reflection.json</a> with the proper function class name and passing Fn FDK libraries with <code>"-Djava.library.path=/lib"</code> in the container CMD along with the <code>"com.example.HelloAIFunction::handleRequest"</code> function handler.
88
115
89
-
5. The German aerospace company Zeppelin began constructing the Hindenburg, a large passenger airship.
Finally deploy the container to your OCI Function by replacing the container using the Cloud UI by editing the function and changing the container from <code>helloworldai-java:1</code> to <code>helloworldai-java:2</code>. Then test it.
@@ -99,6 +134,8 @@ June 13, 2024 is June 13, 1924. Here are some events that occurred on this date:
99
134
- The Fn project is an open-source container-native serverless platform that you can run anywhere -- any cloud or on-premise. It’s easy to use, supports every programming language, and is extensible and performant
- Discover the power of generative AI models equipped with advanced language comprehension for building the next generation of enterprise applications. Oracle Cloud Infrastructure (OCI) Generative AI is a fully managed service for seamlessly integrating these versatile language models into a wide range of use cases, including writing assistance, summarization, analysis, and chat
137
+
-[OCI Functions with GraalVM](https://github.com/shaunsmith/graalvm-fn-init-images)
138
+
- Discover GraalVM Native Image -based functions with this example GitHub repo
Copy file name to clipboardExpand all lines: app-dev/devops-and-containers/functions/java-helloworld-AI-with-local-dev-and-oci-functions/files/src/main/java/com/example/HelloAIFunction.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -70,7 +70,7 @@ Software and the Larger Work(s), and to sublicense the foregoing rights on
Copy file name to clipboardExpand all lines: data-platform/core-converged-db/ai-vector-search/README.md
+6-2Lines changed: 6 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,16 +4,19 @@ Oracle AI Vector Search is designed for Artificial Intelligence (AI) workloads a
4
4
5
5
If you are interested in Database 23ai , [please see our page here](https://github.com/oracle-devrel/technology-engineering/tree/main/data-platform/core-converged-db/database-23ai).
6
6
7
-
Reviewed Date: 20.08.2024
7
+
Reviewed Date: 21.01.2025
8
8
9
9
# Useful Links
10
10
11
11
## Documentation
12
12
13
+
-[What is a Vector Database](https://www.oracle.com/database/vector-database/)
-[Oracle AI Vector Search FAQ](https://www.oracle.com/database/ai-vector-search/faq/)
18
21
19
22
## Blogs & Videos
@@ -36,10 +39,11 @@ Reviewed Date: 20.08.2024
36
39
## Blogs
37
40
38
41
-[Getting started with vectors in 23ai](https://blogs.oracle.com/coretec/post/getting-started-with-vectors-in-23ai)
42
+
-[Hybrid Vector Index - a combination of AI Vector Search with Text Search](https://blogs.oracle.com/coretec/post/hybrid-vector-index-the-combination-of-full-text-and-semantic-vector-search)
0 commit comments