# Could AI artifacts be a blueprint how to enable H5P content in discourse?

**URL:** https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083
**Category:** Development
**Tags:** ai-artifacts
**Created:** [December 7, 2024, 9:27am UTC](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083 "2024-12-07T09:27:53Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![thoka](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/thoka/32/115652_2.png) [@thoka](https://meta.discourse.org/u/thoka)
#### Post date: [December 7, 2024, 9:27am UTC](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083/1 "2024-12-07T09:27:53Z")

</div>

Just wondering if a very similar approach to [Discourse AI - Web Artifacts](https://meta.discourse.org/t/discourse-ai-web-artifacts/339972) would enable to use [H5P](https://h5p.org/) content in discourse.

AI artifacts [are limited in size](https://github.com/discourse/discourse-ai/blob/6ce14a778b02969196545ab7bcc09cad539c1ede/app/models/ai_artifact.rb#L3-L10). I suppose, storing bigger content inside the database should be avoided?

I would like to learn about how to store bigger content and how a limited communication between rich content and discourse could take place.

## Tasks to solve

- **Serve** H5P content from discourse
- **Store** achievements inside discourse
- **Analyze** achievements from discourse
- **Integrate** Achievements with Badges

### Serve H5P content from discourse

H5P content is uploaded as a specific structured zip file. This archive has to be unzipped and moved to locations, from where it can be served.  
Configuration data inside is usually quite small and could be stored in the database, as in AI Web Artifacts (AIWA). Included libraries and media might get quite big and should be stored as other uploads (as files or via CDN).

AIWA serves the content inside an iframe, which provides a sandbox environment. Since any code inside H5P should not be trusted, this seems the way to go for H5P too.

An alternative might be to embed H5P from foreign infrastructure via oneboxing.

### Store achievements inside discourse

H5P uses a REST-API (xAPI) to store achievements. For integration with Discourse UI [cross-document messaging](https://stackoverflow.com/questions/9153445/how-to-communicate-between-iframe-and-the-parent-site) might be interesting.

## Resources

- [Analyzing results and answers | H5P](https://h5p.org/documentation/for-authors/analyzing-results-and-answers)

- [Developer's guide to xAPI: Everything you need to know to start](https://xapi.com/developer-overview/)

---

<div class="post-metadata">

### Author: ![MachineScholar](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/machinescholar/32/424719_2.png) [@MachineScholar](https://meta.discourse.org/u/MachineScholar)
#### Post date: [December 14, 2024, 3:29pm UTC](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083/2 "2024-12-14T15:29:49Z")

</div>

I am also interested in this question! H5P is invaluable for educational communities… 🤓

---

<div class="post-metadata">

### Author: ![thoka](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/thoka/32/115652_2.png) [@thoka](https://meta.discourse.org/u/thoka)
#### Post date: [December 15, 2024, 6:16am UTC](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083/3 "2024-12-15T06:16:28Z")

</div>

I started to think more deeply about a possible integration in the [OP](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083/1).

Discourse could be a tool to use and develop (have meta talks about) H5P content.

---

<div class="post-metadata">

### Author: ![jimkleiber](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jimkleiber/32/121814_2.png) [@jimkleiber](https://meta.discourse.org/u/jimkleiber)
#### Post date: [April 17, 2025, 8:51pm UTC](https://meta.discourse.org/t/could-ai-artifacts-be-a-blueprint-how-to-enable-h5p-content-in-discourse/341083/4 "2025-04-17T20:51:17Z")

</div>

When I discovered AIWA today, this topic is the first thought I had.

Any updates on whether something like this is possible?
