Skip to content

Commit

Permalink
chore: bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
suvam0451 committed Dec 31, 2024
1 parent 0b0f680 commit 7bf95e1
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 60 deletions.
2 changes: 0 additions & 2 deletions apps/mobile/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,4 @@ tokens
# This is your Mastodon client app token
EXPO_PUBLIC_MASTODON_CLIENT_ID=
EXPO_PUBLIC_MASTODON_CLIENT_SECRET=
# This is used by translation service
EXPO_PUBLIC_OPENAI_API_KEY=
```
14 changes: 3 additions & 11 deletions apps/mobile/app.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const expo = ({ config }: ConfigContext): ExpoConfig => ({
...config,
name: IS_DEV ? 'Dhaaga (Dev)' : 'Dhaaga',
slug: 'dhaaga',
version: '0.10.2',
version: '0.11.0',
orientation: 'portrait',
icon: './assets/placeholder_icon.png',
userInterfaceStyle: 'dark',
Expand All @@ -21,7 +21,7 @@ const expo = ({ config }: ConfigContext): ExpoConfig => ({
},
android: {
package: IS_DEV ? 'io.suvam.dhaaga.dev' : 'io.suvam.dhaaga',
versionCode: 14,
versionCode: 15,
},
androidStatusBar: {
barStyle: 'dark-content',
Expand Down Expand Up @@ -74,25 +74,17 @@ const expo = ({ config }: ConfigContext): ExpoConfig => ({
'expo-font',
{
fonts: [
'../../node_modules/@expo-google-fonts/inter/Inter_100Thin.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_200ExtraLight.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_300Light.ttf',
// Inter
'../../node_modules/@expo-google-fonts/inter/Inter_400Regular.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_500Medium.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_600SemiBold.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_700Bold.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_800ExtraBold.ttf',
'../../node_modules/@expo-google-fonts/inter/Inter_900Black.ttf',
// Montserrat
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_100Thin.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_200ExtraLight.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_300Light.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_400Regular.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_500Medium.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_600SemiBold.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_700Bold.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_800ExtraBold.ttf',
'../../node_modules/@expo-google-fonts/montserrat/Montserrat_900Black.ttf',
],
},
],
Expand Down
9 changes: 3 additions & 6 deletions apps/mobile/eas.example.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
"buildType": "app-bundle"
},
"env": {
"APP_VARIANT": "prod",
"EXPO_PUBLIC_OPENAI_API_KEY": ""
"APP_VARIANT": "prod"
}
},
"apk": {
Expand All @@ -16,17 +15,15 @@
"buildType": "apk"
},
"env": {
"APP_VARIANT": "prod",
"EXPO_PUBLIC_OPENAI_API_KEY": ""
"APP_VARIANT": "prod"
}
},
"dev": {
"node": "22.11.0",
"developmentClient": true,
"distribution": "internal",
"env": {
"APP_VARIANT": "dev",
"EXPO_PUBLIC_OPENAI_API_KEY": ""
"APP_VARIANT": "dev"
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion apps/mobile/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dhaaga/mobile",
"version": "0.10.2",
"version": "0.11.0",
"private": true,
"main": "index.js",
"scripts": {
Expand Down
42 changes: 3 additions & 39 deletions apps/mobile/services/openai.service.ts
Original file line number Diff line number Diff line change
@@ -1,41 +1,5 @@
import { HfInference } from '@huggingface/inference';

export class HuggingFaceService {
private static async _infer(input: string, token: string) {
const client = new HfInference(token);

try {
const chatCompletion = await client.chatCompletion({
model: 'meta-llama/Llama-2-7b-chat-hf',
messages: [
{
role: 'system',
content:
'You will be given text content from a social media' +
' post, and your task is to explain it in English.',
},
{
role: 'user',
content: input,
},

{
role: 'user',
content: 'What is the capital of France?',
},
],
max_tokens: 500,
});
console.log(chatCompletion.choices[0].message);
} catch (e) {
return null;
}
}
static async inferServerless(input: string): Promise<string | null> {
return this._infer(input, 'N/A');
}

static async inferDedicated(input: string): Promise<string | null> {
return this._infer(input, 'N/A');
export class OpenAiService {
static async explain(input: string) {
return null;
}
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dhaaga",
"version": "0.10.2",
"version": "0.11.0",
"description": "A fun 🥳 and cozy ☕ microblogging app for the decentralized social web ",
"author": "Debashish Patra <suvam.io>",
"license": "AGPLv3",
Expand Down

0 comments on commit 7bf95e1

Please sign in to comment.