Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/a5c-ai/babysitter --skill room-database명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
Reference for querying the Atlas knowledge graph through its MCP tools — the SECONDARY enrichment/comparison layer that adds best-practice context to systems you have ALREADY scanned from your real sources (`az`, repos, dirs). Use when you need to look up nodes, edges, kinds, clusters, stats, or wiki pages in Atlas to compare against your real inventory. (atlas graph, query atlas, atlas mcp, search the graph, graph neighbors, atlas record, atlas kinds, enrichment layer)
Atlas turns your STATED NEED into a real systems atlas by SCANNING your actual sources (Azure via `az`, git repos, local dirs) and process/data mining them, THEN enriching against the Atlas knowledge graph. Use this skill when asked to inventory/map your real systems, scan your cloud + repos + directories, mine the real processes or data they contain, or collect their real constraints/gotchas. (atlas, scan my systems, inventory our azure account, map my repos, real systems atlas, process mining, data mining, collect nuances, system discovery)
This skill should be used when the user asks to "find skills in the wild", "assimilate popular workflows", "discover SKILL.md files in repos", "research external skills", "find workflow patterns", "survey the skill landscape", "what skills exist out there", or wants to investigate public repositories for extractable processes, babysitter plugins, and reusable procedural insights. Searches GitHub for SKILL.md files, classifies repos by archetype, and maintains structured research under docs/reference-repos/.
SKILL.md 표시 중
SOC 직업 분류 기준
| name | Room Database |
| description | Expert skill for Android Room persistence library |
| version | 1.0.0 |
| category | Android Data Storage |
| slug | android-room |
| status | active |
| graph | {"domains":["domain:mobile"],"specializations":["specialization:mobile-development"],"skillAreas":["skill-area:android-native","skill-area:mobile-local-databases"],"roles":["role:mobile-engineer"],"workflows":["workflow:feature-development","workflow:release-management"],"topics":["topic:accessibility"]} |
This skill provides expert capabilities for Android Room persistence library. It enables designing database schemas, implementing DAOs, configuring migrations, and integrating with modern Android architecture components.
bash - Execute Gradle commands and Android build toolsread - Analyze Room entities and DAO fileswrite - Generate Room database componentsedit - Update existing Room configurationsglob - Search for database-related filesgrep - Search for patterns in database codeEntity Definition
Type Converters
Query Methods
Reactive Queries
Database Setup
Migrations
Hilt Integration
Repository Pattern
This skill integrates with the following processes:
android-room-database.js - Room implementationoffline-first-architecture.js - Offline data strategiesmobile-security-implementation.js - Secure data storage// build.gradle.kts (app)
plugins {
id("com.google.devtools.ksp")
}
dependencies {
implementation(libs.room.runtime)
implementation(libs.room.ktx)
ksp(libs.room.compiler)
// Optional - Paging 3 Integration
implementation(libs.room.paging)
// Testing
testImplementation(libs.room.testing)
}
# gradle/libs.versions.toml
[versions]
room = "2.6.1"
[libraries]
room-runtime = { group = "androidx.room", name = "room-runtime", version.ref = "room" }
room-ktx = { group = "androidx.room", name = "room-ktx", version.ref = "room" }
room-compiler = { group = "androidx.room", name = "room-compiler", version.ref = "room" }
room-paging = { group = "androidx.room", name = "room-paging", version.ref = "room" }
room-testing = { group = "androidx.room", name = "room-testing", version.ref = "room" }
// data/local/entity/UserEntity.kt
package com.example.app.data.local.entity
import androidx.room.*
@Entity(
tableName = "users",
indices = [
Index(value = ["email"], unique = true),
Index(value = ["created_at"])
]
)
data class UserEntity(
@PrimaryKey
@ColumnInfo(name = "id")
val id: String,
@ColumnInfo(name = "email")
val email: String,
@ColumnInfo(name = "display_name")
val displayName: String,
@ColumnInfo(name = "avatar_url")
val avatarUrl: String?,
@ColumnInfo(name = "created_at")
val createdAt: Long,
@ColumnInfo(name = "updated_at")
val updatedAt: Long,
@Embedded(prefix = "settings_")
val settings: UserSettings
)
data class UserSettings(
@ColumnInfo(name = "notifications_enabled")
val notificationsEnabled: Boolean = true,
@ColumnInfo(name = "theme")
val theme: String = "system"
)
// data/local/entity/PostEntity.kt
package com.example.app.data.local.entity
import androidx.room.*
@Entity(
tableName = "posts",
foreignKeys = [
ForeignKey(
entity = UserEntity::class,
parentColumns = ["id"],
childColumns = ["author_id"],
onDelete = ForeignKey.CASCADE
)
],
indices = [Index(value = ["author_id"])]
)
data class PostEntity(
@PrimaryKey
@ColumnInfo(name = "id")
val id: String,
@ColumnInfo(name = "author_id")
val authorId: String,
@ColumnInfo(name = "title")
val title: String,
@ColumnInfo(name = "content")
val content: String,
@ColumnInfo(name = "published_at")
val publishedAt: Long?,
@ColumnInfo(name = "is_draft")
val isDraft: Boolean = true
)
// Relation class for queries
data class PostWithAuthor(
@Embedded val post: PostEntity,
@Relation(
parentColumn = "author_id",
entityColumn = "id"
)
val author: UserEntity
)
// data/local/converter/Converters.kt
package com.example.app.data.local.converter
import androidx.room.TypeConverter
import java.time.Instant
import java.time.LocalDateTime
import java.time.ZoneId
class Converters {
@TypeConverter
fun fromTimestamp(value: Long?): LocalDateTime? {
return value?.let {
LocalDateTime.ofInstant(Instant.ofEpochMilli(it), ZoneId.systemDefault())
}
}
@TypeConverter
fun toTimestamp(date: LocalDateTime?): Long? {
return date?.atZone(ZoneId.systemDefault())?.toInstant()?.toEpochMilli()
}
@TypeConverter
fun fromStringList(value: List<String>?): String? {
return value?.joinToString(",")
}
@TypeConverter
fun toStringList(value: String?): List<String>? {
return value?.split(",")?.map { it.trim() }
}
}
// data/local/dao/UserDao.kt
package com.example.app.data.local.dao
import androidx.room.*
import kotlinx.coroutines.flow.Flow
@Dao
interface UserDao {
@Query("SELECT * FROM users ORDER BY display_name ASC")
fun observeAllUsers(): Flow<List<UserEntity>>
@Query("SELECT * FROM users WHERE id = :userId")
fun observeUserById(userId: String): Flow<UserEntity?>
@Query("SELECT * FROM users WHERE id = :userId")
suspend fun getUserById(userId: String): UserEntity?
@Query("SELECT * FROM users WHERE email = :email LIMIT 1")
suspend fun getUserByEmail(email: String): UserEntity?
@Insert(onConflict = OnConflictStrategy.REPLACE)
suspend fun insertUser(user: UserEntity)
@Insert(onConflict = OnConflictStrategy.REPLACE)
suspend fun insertUsers(users: List<UserEntity>)
{
deleteAllUsers()
insertUsers(users)
}
}
// data/local/dao/PostDao.kt
package com.example.app.data.local.dao
import androidx.room.*
import androidx.paging.PagingSource
import kotlinx.coroutines.flow.Flow
@Dao
interface PostDao {
@Transaction
@Query("SELECT * FROM posts WHERE is_draft = 0 ORDER BY published_at DESC")
fun observePublishedPostsWithAuthor(): Flow<List<PostWithAuthor>>
@Transaction
@Query("SELECT * FROM posts WHERE is_draft = 0 ORDER BY published_at DESC")
fun getPublishedPostsPagingSource(): PagingSource<Int, PostWithAuthor>
@Transaction
@Query("SELECT * FROM posts WHERE id = :postId")
suspend fun getPostWithAuthor(postId: String): PostWithAuthor?
@Query("SELECT * FROM posts WHERE author_id = :authorId ORDER BY published_at DESC")
fun observePostsByAuthor(authorId: String): Flow<List<PostEntity>>
@Query("""
SELECT * FROM posts
WHERE title LIKE '%' || :query || '%'
OR content LIKE '%' || :query || '%'
ORDER BY published_at DESC
""")
suspend fun searchPosts(query: ): List<PostEntity>
}
// data/local/AppDatabase.kt
package com.example.app.data.local
import androidx.room.*
import com.example.app.data.local.converter.Converters
import com.example.app.data.local.dao.PostDao
import com.example.app.data.local.dao.UserDao
import com.example.app.data.local.entity.PostEntity
import com.example.app.data.local.entity.UserEntity
@Database(
entities = [
UserEntity::class,
PostEntity::class
],
version = 2,
autoMigrations = [
AutoMigration(from = 1, to = 2)
],
exportSchema = true
)
@TypeConverters(Converters::class)
abstract class AppDatabase : RoomDatabase() {
abstract fun userDao(): UserDao
abstract fun postDao(): PostDao
}
// di/DatabaseModule.kt
package com.example.app.di
import android.content.Context
import androidx.room.Room
import com.example.app.data.local.AppDatabase
import com.example.app.data.local.dao.PostDao
import com.example.app.data.local.dao.UserDao
import dagger.Module
import dagger.Provides
import dagger.hilt.InstallIn
import dagger.hilt.android.qualifiers.ApplicationContext
import dagger.hilt.components.SingletonComponent
import javax.inject.Singleton
@Module
@InstallIn(SingletonComponent::class)
object DatabaseModule {
@Provides
@Singleton
fun provideAppDatabase(
@ApplicationContext context: Context
): AppDatabase {
return Room.databaseBuilder(
context,
AppDatabase::class.java,
"app_database"
)
.fallbackToDestructiveMigration()
.build()
}
@Provides
fun provideUserDao(database: AppDatabase): UserDao = database.userDao()
@Provides
fun providePostDao(database: AppDatabase): PostDao = database.postDao()
}
// data/repository/UserRepositoryImpl.kt
package com.example.app.data.repository
import com.example.app.data.local.dao.UserDao
import com.example.app.data.local.entity.UserEntity
import com.example.app.data.remote.api.UserApi
import com.example.app.domain.model.User
import com.example.app.domain.repository.UserRepository
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
import javax.inject.Inject
class UserRepositoryImpl @Inject constructor(
private val userDao: UserDao,
private val userApi: UserApi
) : UserRepository {
override fun observeUsers(): Flow<List<User>> {
return userDao.observeAllUsers().map { entities ->
entities.map { it.toDomain() }
}
}
override fun observeUser(userId: String): Flow<User?> {
return userDao.observeUserById(userId).map { it?.toDomain() }
}
override suspend fun refreshUsers() {
val remoteUsers = userApi.getUsers()
val entities = remoteUsers.map { it.toEntity() }
userDao.replaceAllUsers(entities)
}
override suspend : User? {
userDao.getUserById(userId)?.toDomain()
}
}
= User(
id = id,
email = email,
displayName = displayName,
avatarUrl = avatarUrl
)
kotlin-compose - Android UI developmentoffline-storage - Cross-platform patternsmobile-security - Encrypted databases