Compare commits
5 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
579ffb3ee9 | ||
|
|
bac1c24a9c | ||
|
|
f9e363b2fb | ||
|
|
ff3e29215c | ||
|
|
e3fed39af1 |
7 changed files with 90 additions and 13 deletions
56
.github/workflows/build-multiarch.yml
vendored
56
.github/workflows/build-multiarch.yml
vendored
|
|
@ -4,6 +4,60 @@ on:
|
|||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-python-packages:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.13'
|
||||
|
||||
- name: Install uv
|
||||
uses: astral-sh/setup-uv@v3
|
||||
|
||||
- name: Extract version from pyproject.toml
|
||||
id: version
|
||||
run: |
|
||||
VERSION=$(grep '^version = ' pyproject.toml | cut -d '"' -f 2)
|
||||
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
||||
echo "Version: $VERSION"
|
||||
|
||||
- name: Build wheel and source distribution
|
||||
run: |
|
||||
uv build
|
||||
|
||||
- name: List built artifacts
|
||||
run: |
|
||||
ls -la dist/
|
||||
echo "Built artifacts:"
|
||||
for file in dist/*; do
|
||||
echo " - $(basename $file) ($(stat -c%s $file | numfmt --to=iec-i)B)"
|
||||
done
|
||||
|
||||
- name: Upload build artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: python-packages
|
||||
path: dist/
|
||||
retention-days: 30
|
||||
|
||||
- name: Create Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
tag_name: v${{ steps.version.outputs.version }}
|
||||
name: Release ${{ steps.version.outputs.version }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
generate_release_notes: true
|
||||
files: |
|
||||
dist/*.whl
|
||||
dist/*.tar.gz
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
build:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
|
|
@ -100,7 +154,7 @@ jobs:
|
|||
cache-to: type=gha,mode=max,scope=${{ matrix.image }}-${{ matrix.arch }}
|
||||
|
||||
manifest:
|
||||
needs: build
|
||||
needs: [build, build-python-packages]
|
||||
runs-on: ubuntu-latest
|
||||
if: github.event_name != 'pull_request'
|
||||
steps:
|
||||
|
|
|
|||
|
|
@ -64,31 +64,31 @@ export const MarkdownRenderer = ({ chatMessage }: MarkdownRendererProps) => {
|
|||
rehypePlugins={[rehypeMathjax, rehypeRaw]}
|
||||
linkTarget="_blank"
|
||||
components={{
|
||||
p({ node, ...props }) {
|
||||
p: ({ node, ...props }: any) => {
|
||||
return <p className="w-fit max-w-full">{props.children}</p>;
|
||||
},
|
||||
ol({ node, ...props }) {
|
||||
ol: ({ node, ...props }: any) => {
|
||||
return <ol className="max-w-full">{props.children}</ol>;
|
||||
},
|
||||
h1({ node, ...props }) {
|
||||
h1: ({ node, ...props }: any) => {
|
||||
return <h1 className="mb-6 mt-4">{props.children}</h1>;
|
||||
},
|
||||
h2({ node, ...props }) {
|
||||
h2: ({ node, ...props }: any) => {
|
||||
return <h2 className="mb-4 mt-4">{props.children}</h2>;
|
||||
},
|
||||
h3({ node, ...props }) {
|
||||
h3: ({ node, ...props }: any) => {
|
||||
return <h3 className="mb-2 mt-4">{props.children}</h3>;
|
||||
},
|
||||
hr({ node, ...props }) {
|
||||
hr: ({ node, ...props }: any) => {
|
||||
return <hr className="w-full mt-4 mb-8" />;
|
||||
},
|
||||
ul({ node, ...props }) {
|
||||
ul: ({ node, ...props }: any) => {
|
||||
return <ul className="max-w-full mb-2">{props.children}</ul>;
|
||||
},
|
||||
pre({ node, ...props }) {
|
||||
pre: ({ node, ...props }: any) => {
|
||||
return <>{props.children}</>;
|
||||
},
|
||||
table: ({ node, ...props }) => {
|
||||
table: ({ node, ...props }: any) => {
|
||||
return (
|
||||
<div className="max-w-full overflow-hidden rounded-md border bg-muted">
|
||||
<div className="max-h-[600px] w-full overflow-auto p-4">
|
||||
|
|
@ -98,7 +98,7 @@ export const MarkdownRenderer = ({ chatMessage }: MarkdownRendererProps) => {
|
|||
);
|
||||
},
|
||||
|
||||
code: ({ node, className, inline, children, ...props }) => {
|
||||
code: ({ node, className, inline, children, ...props }: any) => {
|
||||
let content = children as string;
|
||||
if (
|
||||
Array.isArray(children) &&
|
||||
|
|
|
|||
11
frontend/package-lock.json
generated
11
frontend/package-lock.json
generated
|
|
@ -52,6 +52,7 @@
|
|||
"@types/node": "^20",
|
||||
"@types/react": "^19",
|
||||
"@types/react-dom": "^19",
|
||||
"@types/react-syntax-highlighter": "^15.5.13",
|
||||
"autoprefixer": "^10.4.21",
|
||||
"eslint": "^9",
|
||||
"eslint-config-next": "15.3.5",
|
||||
|
|
@ -2323,6 +2324,16 @@
|
|||
"@types/react": "^19.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@types/react-syntax-highlighter": {
|
||||
"version": "15.5.13",
|
||||
"resolved": "https://registry.npmjs.org/@types/react-syntax-highlighter/-/react-syntax-highlighter-15.5.13.tgz",
|
||||
"integrity": "sha512-uLGJ87j6Sz8UaBAooU0T6lWJ0dBmjZgN1PZTrj05TNql2/XpC6+4HhMT5syIdFUUt+FASfCeLLv4kBygNU+8qA==",
|
||||
"dev": true,
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@types/react": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/@types/trusted-types": {
|
||||
"version": "2.0.7",
|
||||
"resolved": "https://registry.npmjs.org/@types/trusted-types/-/trusted-types-2.0.7.tgz",
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@
|
|||
"@types/node": "^20",
|
||||
"@types/react": "^19",
|
||||
"@types/react-dom": "^19",
|
||||
"@types/react-syntax-highlighter": "^15.5.13",
|
||||
"autoprefixer": "^10.4.21",
|
||||
"eslint": "^9",
|
||||
"eslint-config-next": "15.3.5",
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@
|
|||
"resolveJsonModule": true,
|
||||
"isolatedModules": true,
|
||||
"jsx": "preserve",
|
||||
"jsxImportSource": "react",
|
||||
"incremental": true,
|
||||
"plugins": [
|
||||
{
|
||||
|
|
@ -22,6 +23,6 @@
|
|||
"@/*": ["./src/*", "./*"]
|
||||
}
|
||||
},
|
||||
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
|
||||
"include": ["next-env.d.ts", "types/**/*.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
|
||||
"exclude": ["node_modules"]
|
||||
}
|
||||
|
|
|
|||
10
frontend/types/global.d.ts
vendored
Normal file
10
frontend/types/global.d.ts
vendored
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
/// <reference types="react" />
|
||||
/// <reference types="react-dom" />
|
||||
|
||||
declare global {
|
||||
namespace JSX {
|
||||
interface IntrinsicElements extends React.JSX.IntrinsicElements {}
|
||||
}
|
||||
}
|
||||
|
||||
export {};
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
[project]
|
||||
name = "openrag"
|
||||
version = "0.1.3"
|
||||
version = "0.1.4-rc.1"
|
||||
description = "Add your description here"
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.13"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue